Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
apply: carefully strdup a possibly-NULL name
[gitweb.git]
/
builtin
/
apply.c
diff --git
a/builtin/apply.c
b/builtin/apply.c
index b4428ea34f53d94e3733796777866e73531f06b5..f69a864abe8073b60a0cef743e98d249e3005796 100644
(file)
--- a/
builtin/apply.c
+++ b/
builtin/apply.c
@@
-898,7
+898,7
@@
static void parse_traditional_patch(const char *first, const char *second, struc
patch->old_name = name;
} else {
patch->old_name = name;
- patch->new_name =
x
strdup(name);
+ patch->new_name =
null_
strdup(name);
}
}
if (!name)