diff options
author | Werner Koch <wk@gnupg.org> | 1998-08-11 19:29:34 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 1998-08-11 19:29:34 +0200 |
commit | 3e0e8f884f1ed37e120beeb57aa7cd79e3c145a0 (patch) | |
tree | dfff62df60f917addc9df4e83a1ed73e31041bab /g10/dearmor.c | |
parent | rel 0.3.3 (diff) | |
download | gnupg2-3e0e8f884f1ed37e120beeb57aa7cd79e3c145a0.tar.xz gnupg2-3e0e8f884f1ed37e120beeb57aa7cd79e3c145a0.zip |
bug fix releaseV0-3-4
Diffstat (limited to 'g10/dearmor.c')
-rw-r--r-- | g10/dearmor.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/g10/dearmor.c b/g10/dearmor.c index 5fa038255..6b15f491b 100644 --- a/g10/dearmor.c +++ b/g10/dearmor.c @@ -58,10 +58,9 @@ dearmor_file( const char *fname ) iobuf_push_filter( inp, armor_filter, &afx ); - if( !(out = open_outfile( fname, 0 )) ) { - rc = G10ERR_CREATE_FILE; + if( (rc = open_outfile( fname, 0, &out )) ) goto leave; - } + while( (c = iobuf_get(inp)) != -1 ) @@ -100,10 +99,8 @@ enarmor_file( const char *fname ) } - if( !(out = open_outfile( fname, 1 )) ) { - rc = G10ERR_CREATE_FILE; + if( (rc = open_outfile( fname, 1, &out )) ) goto leave; - } afx.what = 4; afx.hdrlines = "Comment: Use \"gpgm --dearmor\" for unpacking\n"; |