mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
* plaintext.c (handle_plaintext): Don't try and create a zero-length
filename when using --use-embedded-filename with input that has no filename (clearsigned or message generated from a pipe). * encode.c (encode_simple, encode_crypt), progress.c (handle_progress), sign.c (write_plaintext_packet): Fix a few inconsistent calls (NULL filename means a pipe here, so don't bother to check it twice).
This commit is contained in:
parent
c09b34fede
commit
69ef25f8d6
5 changed files with 31 additions and 18 deletions
|
@ -105,13 +105,14 @@ handle_plaintext( PKT_plaintext *pt, md_filter_context_t *mfx,
|
|||
|
||||
if( nooutput )
|
||||
;
|
||||
else if ( iobuf_is_pipe_filename (fname) ) {
|
||||
else if ( iobuf_is_pipe_filename (fname) || !*fname)
|
||||
{
|
||||
/* No filename or "-" given; write to stdout. */
|
||||
fp = stdout;
|
||||
#ifdef HAVE_DOSISH_SYSTEM
|
||||
setmode ( fileno(fp) , O_BINARY );
|
||||
#endif
|
||||
}
|
||||
}
|
||||
else {
|
||||
while( !overwrite_filep (fname) ) {
|
||||
char *tmp = ask_outfile_name (NULL, 0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue