diff options
Diffstat (limited to 'boot')
-rw-r--r-- | boot/pxe_utils.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/boot/pxe_utils.c b/boot/pxe_utils.c index b59e959f715..c613818d0b3 100644 --- a/boot/pxe_utils.c +++ b/boot/pxe_utils.c @@ -1179,11 +1179,10 @@ static int parse_label_kernel(char **c, struct pxe_label *label) if (!s) return 1; - label->config = malloc(strlen(s) + 1); + label->config = strdup(s); if (!label->config) return -ENOMEM; - strcpy(label->config, s); *s = 0; return 1; |