projects
/
krb5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
27e9321
)
Use strdup
author
Ken Raeburn
<raeburn@mit.edu>
Wed, 4 Jul 2007 04:27:32 +0000
(
04:27
+0000)
committer
Ken Raeburn
<raeburn@mit.edu>
Wed, 4 Jul 2007 04:27:32 +0000
(
04:27
+0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19671
dc483132
-0cff-0310-8789-
dd5450dbe970
src/lib/gssapi/generic/util_buffer.c
patch
|
blob
|
history
diff --git
a/src/lib/gssapi/generic/util_buffer.c
b/src/lib/gssapi/generic/util_buffer.c
index 77cb2eb2ffe4d26017f1368b619f33828f9e35be..9b814b00a167a280d869eb55467ca266eff221be 100644
(file)
--- a/
src/lib/gssapi/generic/util_buffer.c
+++ b/
src/lib/gssapi/generic/util_buffer.c
@@
-37,12
+37,10
@@
int g_make_string_buffer(str, buffer)
{
buffer->length = strlen(str);
- if ((buffer->value =
(void *) xmalloc(buffer->length + 1
)) == NULL) {
+ if ((buffer->value =
strdup(str
)) == NULL) {
buffer->length = 0;
return(0);
}
- strcpy(buffer->value, str);
-
return(1);
}