diff options
-rw-r--r-- | src/appl/gss-sample/ChangeLog | 6 | ||||
-rw-r--r-- | src/appl/gss-sample/gss-misc.c | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/src/appl/gss-sample/ChangeLog b/src/appl/gss-sample/ChangeLog index 5a5cf81d34..7eedd70e63 100644 --- a/src/appl/gss-sample/ChangeLog +++ b/src/appl/gss-sample/ChangeLog @@ -1,6 +1,10 @@ +2001-11-07 Ezra Peisach <epeisach@mit.edu> + + * gss-misc.c (recv_token): Do not attempt to malloc 0 bytes. + 2001-11-01 Sam Hartman <hartmans@mit.edu> - * gss-server.c gss-client.c: ONly free buffers returned from + * gss-server.c gss-client.c: Only free buffers returned from GSSAPI using gss_release_buffer * gss-client.c (client_establish_context): Trailing null should diff --git a/src/appl/gss-sample/gss-misc.c b/src/appl/gss-sample/gss-misc.c index 78e5d2fd8c..0fc6d9295d 100644 --- a/src/appl/gss-sample/gss-misc.c +++ b/src/appl/gss-sample/gss-misc.c @@ -214,7 +214,7 @@ int recv_token(s, flags, tok) } tok->length = ntohl(tok->length); - tok->value = (char *) malloc(tok->length); + tok->value = (char *) malloc(tok->length ? tok->length : 1); if (tok->length && tok->value == NULL) { if (display_file) fprintf(display_file, |