diff options
-rw-r--r-- | src/appl/gssftp/ftp/ChangeLog | 7 | ||||
-rw-r--r-- | src/appl/gssftp/ftp/secure.c | 18 |
2 files changed, 16 insertions, 9 deletions
diff --git a/src/appl/gssftp/ftp/ChangeLog b/src/appl/gssftp/ftp/ChangeLog index e043f104e9..77fe445cb7 100644 --- a/src/appl/gssftp/ftp/ChangeLog +++ b/src/appl/gssftp/ftp/ChangeLog @@ -1,3 +1,10 @@ +2006-03-30 Ken Raeburn <raeburn@mit.edu> + + * secure.c: Include autoconf.h. Include stdint.h and inttypes.h + if available. + (ftp_uint32, ftp_int32): Always define as [u]int32_t instead of + testing configure-time type size macros. + 2006-02-24 Jeffrey Altman <jaltman@mit.edu> * Makefile.in: support for 64-bit Windows builds diff --git a/src/appl/gssftp/ftp/secure.c b/src/appl/gssftp/ftp/secure.c index 999641b772..52fda8cac8 100644 --- a/src/appl/gssftp/ftp/secure.c +++ b/src/appl/gssftp/ftp/secure.c @@ -3,6 +3,8 @@ * secure read(), write(), getc(), and putc(). * Only one security context, thus only work on one fd at a time! */ +#include "autoconf.h" + #ifdef GSSAPI #include <gssapi/gssapi.h> #include <gssapi/gssapi_generic.h> @@ -49,16 +51,14 @@ extern char *sys_errlist[]; #endif #endif -#if (SIZEOF_SHORT == 4) -typedef unsigned short ftp_uint32; -typedef short ftp_int32; -#elif (SIZEOF_INT == 4) -typedef unsigned int ftp_uint32; -typedef int ftp_int32; -#elif (SIZEOF_LONG == 4) -typedef unsigned long ftp_uint32; -typedef long ftp_int32; +#ifdef HAVE_STDINT_H +# include <stdint.h> +#endif +#ifdef HAVE_INTTYPES_H +# include <inttypes.h> #endif +typedef uint32_t ftp_uint32; +typedef int32_t ftp_int32; static int secure_putbuf (int, unsigned char *, unsigned int); |