aboutsummaryrefslogtreecommitdiff
path: root/editors
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2009-04-22 22:34:14 +1000
committerNguyễn Thái Ngọc Duy <pclouds@gmail.com>2009-04-23 04:44:38 +1000
commit9edc74053e3233e5c0aac2a966785c4ece7e55aa (patch)
treedf6d5fa6b49f54c072de131d4e34ec6353510071 /editors
parent8261931d1b3ed1a5efec057f623738388f4ed39e (diff)
downloadbusybox-w32-9edc74053e3233e5c0aac2a966785c4ece7e55aa.tar.gz
busybox-w32-9edc74053e3233e5c0aac2a966785c4ece7e55aa.tar.bz2
busybox-w32-9edc74053e3233e5c0aac2a966785c4ece7e55aa.zip
editors/patch: support /dev/null
Diffstat (limited to 'editors')
-rw-r--r--editors/patch.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/editors/patch.c b/editors/patch.c
index f65bbf4f9..65b8f659b 100644
--- a/editors/patch.c
+++ b/editors/patch.c
@@ -121,6 +121,10 @@ int patch_main(int argc, char **argv)
121 121
122 /* Extract the filename used before the patch was generated */ 122 /* Extract the filename used before the patch was generated */
123 original_filename = extract_filename(patch_line, patch_level); 123 original_filename = extract_filename(patch_line, patch_level);
124#ifdef __MINGW32__
125 if (!strcmp(original_filename, "/dev/null"))
126 original_filename = "nul";
127#endif
124 free(patch_line); 128 free(patch_line);
125 129
126 patch_line = xmalloc_fgets(patch_file); 130 patch_line = xmalloc_fgets(patch_file);