NULL of the string in the gss buffer's length.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10580
dc483132-0cff-0310-8789-
dd5450dbe970
+Sun May 24 22:01:29 1998 Theodore Y. Ts'o <tytso@mit.edu>
+
+ * util_buffer.c (g_make_string_buffer): Don't include the trailing
+ NULL of the string in the gss buffer's length.
+
1998-05-18 Theodore Ts'o <tytso@rsts-11.mit.edu>
* util_ordering.c (g_order_free):
const char *str;
gss_buffer_t buffer;
{
- buffer->length = strlen(str)+1;
+ buffer->length = strlen(str);
- if ((buffer->value = (void *) xmalloc(buffer->length)) == NULL) {
+ if ((buffer->value = (void *) xmalloc(buffer->length + 1)) == NULL) {
buffer->length = 0;
return(0);
}