Skip to content

Commit

Permalink
rpc: include <limits.h> for definition of ULONG_MAX
Browse files Browse the repository at this point in the history
Fixes build failure on Solaris 11.4 with gcc 14.2:
../p11-kit/rpc-server.c: In function ‘proto_read_attribute_buffer_array’:
../p11-kit/rpc-server.c:289:46: error: ‘ULONG_MAX’ undeclared (first use in this function)
  289 |                         if ((n_array != 0 && ULONG_MAX / n_array < sizeof (CK_ATTRIBUTE)) ||
      |                                              ^~~~~~~~~
../p11-kit/rpc-server.c:64:1: note: ‘ULONG_MAX’ is defined in header ‘<limits.h>’; this is probably fixable by adding ‘#include <limits.h>’

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
  • Loading branch information
alanc authored and ueno committed Oct 11, 2024
1 parent a8b9464 commit e3460db
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions p11-kit/rpc-server.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
#include <sys/param.h>
#include <assert.h>
#include <errno.h>
#include <limits.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
Expand Down

0 comments on commit e3460db

Please sign in to comment.