diff options
author | Ken Raeburn <raeburn@mit.edu> | 2006-03-31 02:10:57 +0000 |
---|---|---|
committer | Ken Raeburn <raeburn@mit.edu> | 2006-03-31 02:10:57 +0000 |
commit | dca45ec6cd8f7ae9e801c6b67a310e66d7a3984f (patch) | |
tree | 2ca632e6f618584250d2941a590497d60963d8db /src/appl/gssftp/ftp | |
parent | afd5eb7ee761696dc499a0532df7483d95d68a47 (diff) | |
download | krb5-dca45ec6cd8f7ae9e801c6b67a310e66d7a3984f.tar.gz krb5-dca45ec6cd8f7ae9e801c6b67a310e66d7a3984f.tar.xz krb5-dca45ec6cd8f7ae9e801c6b67a310e66d7a3984f.zip |
* 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.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@17816 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/appl/gssftp/ftp')
-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 e043f104e..77fe445cb 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 999641b77..52fda8cac 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); |