patch: support "patch [FILE [PATCH]]" format
function old new delta xopen_stdin - 15 +15 patch_main 2075 2041 -34 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
@@ -46,3 +46,11 @@ int FAST_FUNC open_or_warn_stdin(const char *filename)
|
||||
|
||||
return fd;
|
||||
}
|
||||
|
||||
int FAST_FUNC xopen_stdin(const char *filename)
|
||||
{
|
||||
int fd = open_or_warn_stdin(filename);
|
||||
if (fd >= 0)
|
||||
return fd;
|
||||
xfunc_die(); /* We already output an error message. */
|
||||
}
|
||||
|
Reference in New Issue
Block a user