diff options
author | Hib Eris <hib@hiberis.nl> | 2010-04-13 23:54:28 +0200 |
---|---|---|
committer | Albert Astals Cid <aacid@kde.org> | 2010-04-14 23:14:57 +0100 |
commit | 24f244f486f332b0bd76c6525c5d9d03168a76e6 (patch) | |
tree | c89db65919c484e8e4738ad191fad7ca357c124c /utils | |
parent | 955f9f53ff225f6794a494fdd0f0fe5ee1a41d88 (diff) |
pdftops: require output filename when reading from stdin
Diffstat (limited to 'utils')
-rw-r--r-- | utils/pdftops.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/utils/pdftops.cc b/utils/pdftops.cc index 0376e2fc..0bc43a1f 100644 --- a/utils/pdftops.cc +++ b/utils/pdftops.cc @@ -330,6 +330,9 @@ int main(int argc, char *argv[]) { // construct PostScript file name if (argc == 3) { psFileName = new GooString(argv[2]); + } else if (fileName->cmp("fd://0") == 0) { + error(-1, "You have to provide an output filename when reading form stdin."); + goto err1; } else { p = fileName->getCString() + fileName->getLength() - 4; if (!strcmp(p, ".pdf") || !strcmp(p, ".PDF")) { |