On Wed, 11 Apr 2012, Sunil Nimmagadda wrote:
> Description:
> According to patch(1) manpage, if patchfile is omitted or is a
> hyphen it should read from standard input, instead it errs out with a
> message "can't find -".
>
> How-To-Repeat:
> cat somediff | patch -
To quote the manapage, the synopsis is:
patch [-bCcEeflNnRstuv] [-B backup-prefix] [-D symbol] [-d directory]
[-F max-fuzz] [-i patchfile] [-o out-file] [-p strip-count]
[-r rej-name] [-V t | nil | never] [-x number] [-z backup-ext]
[--posix] [origfile [patchfile]]
Note that last bit: [origfile [patchfile]]
That means that if you only supply one positional argument then it must be
interpreted as the 'origfile' instead the 'patchfile'. So, the current
behavior is correct.
Philip Guenther