svn rev #24594: trunk/src/lib/gssapi/krb5/

raeburn@MIT.EDU raeburn at MIT.EDU
Wed Jan 12 17:00:40 EST 2011


http://src.mit.edu/fisheye/changelog/krb5/?cs=24594
Commit By: raeburn
Log Message:
Don't call memset with a zero length.


Changed Files:
U   trunk/src/lib/gssapi/krb5/k5sealv3.c
Modified: trunk/src/lib/gssapi/krb5/k5sealv3.c
===================================================================
--- trunk/src/lib/gssapi/krb5/k5sealv3.c	2011-01-11 20:00:52 UTC (rev 24593)
+++ trunk/src/lib/gssapi/krb5/k5sealv3.c	2011-01-12 22:00:40 UTC (rev 24594)
@@ -159,7 +159,8 @@
         store_64_be(ctx->seq_send, outbuf+8);
 
         memcpy(plain.data, message->value, message->length);
-        memset(plain.data + message->length, 'x', ec);
+        if (ec != 0)
+            memset(plain.data + message->length, 'x', ec);
         memcpy(plain.data + message->length + ec, outbuf, 16);
 
         cipher.ciphertext.data = (char *)outbuf + 16;




More information about the cvs-krb5 mailing list