Commit 50192b72 authored by Alan Coopersmith's avatar Alan Coopersmith Committed by Ulrich Sibiller

lcPubWrap: replace malloc(strlen) + strcpy with strdup

parent 7a1fc175
......@@ -78,10 +78,9 @@ _XlcCreateLC(
return (XLCd) NULL;
if (lcd->core->name == NULL) {
lcd->core->name = Xmalloc(strlen(name) + 1);
lcd->core->name = strdup(name);
if (lcd->core->name == NULL)
goto err;
strcpy(lcd->core->name, name);
}
if (lcd->methods == NULL)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment