mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
* sign.c (write_plaintext_packet)
* progress.c (handle_progress) * encode.c (encode_simple,encode_crypt): Make sure that a filename of "-" is considered to be stdin so that iobuf_get_filelength won't get called. This fixes bug 156 reported by Gregery Barton.
This commit is contained in:
parent
905e6b2528
commit
847c935307
4 changed files with 16 additions and 5 deletions
|
@ -294,7 +294,8 @@ encode_simple( const char *filename, int mode, int compat )
|
|||
either partial length or fixed length with the new style
|
||||
messages. */
|
||||
|
||||
if( filename && !opt.textmode ) {
|
||||
if (filename && *filename && !(*filename == '-' && !filename[1])
|
||||
&& !opt.textmode ) {
|
||||
off_t tmpsize;
|
||||
|
||||
if ( !(tmpsize = iobuf_get_filelength(inp)) )
|
||||
|
@ -525,7 +526,8 @@ encode_crypt( const char *filename, STRLIST remusr )
|
|||
}
|
||||
}
|
||||
|
||||
if( filename && !opt.textmode ) {
|
||||
if (filename && *filename && !(*filename == '-' && !filename[1])
|
||||
&& !opt.textmode ) {
|
||||
off_t tmpsize;
|
||||
|
||||
if ( !(tmpsize = iobuf_get_filelength(inp)) )
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue