1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

* Makefile.am (AM_CFLAGS): Make use of AM_CFLAGS and AM_LDFLAGS.

* g10.c, options.h: New option --enable-progress-filter.
* progress.c (handle_progress): Make use of it.
This commit is contained in:
Werner Koch 2003-04-15 15:46:13 +00:00
parent fc3cc2cacf
commit b394776a80
13 changed files with 209 additions and 17 deletions

View file

@ -631,6 +631,7 @@ sign_file( STRLIST filenames, int detached, STRLIST locusr,
compress_filter_context_t zfx;
md_filter_context_t mfx;
text_filter_context_t tfx;
progress_filter_context_t pfx;
encrypt_filter_context_t efx;
IOBUF inp = NULL, out = NULL;
PACKET pkt;
@ -677,11 +678,15 @@ sign_file( STRLIST filenames, int detached, STRLIST locusr,
/* prepare iobufs */
if( multifile ) /* have list of filenames */
inp = NULL; /* we do it later */
else if( !(inp = iobuf_open(fname)) ) {
log_error("can't open %s: %s\n", fname? fname: "[stdin]",
strerror(errno) );
rc = G10ERR_OPEN_FILE;
goto leave;
else {
if( !(inp = iobuf_open(fname)) ) {
log_error("can't open %s: %s\n", fname? fname: "[stdin]",
strerror(errno) );
rc = G10ERR_OPEN_FILE;
goto leave;
}
handle_progress (&pfx, inp, fname);
}
if( outfile ) {
@ -819,6 +824,7 @@ sign_file( STRLIST filenames, int detached, STRLIST locusr,
rc = G10ERR_OPEN_FILE;
goto leave;
}
handle_progress (&pfx, inp, sl->d);
if( opt.verbose )
fprintf(stderr, " `%s'", sl->d );
if(opt.textmode)
@ -882,6 +888,7 @@ int
clearsign_file( const char *fname, STRLIST locusr, const char *outfile )
{
armor_filter_context_t afx;
progress_filter_context_t pfx;
MD_HANDLE textmd = NULL;
IOBUF inp = NULL, out = NULL;
PACKET pkt;
@ -919,6 +926,7 @@ clearsign_file( const char *fname, STRLIST locusr, const char *outfile )
rc = G10ERR_OPEN_FILE;
goto leave;
}
handle_progress (&pfx, inp, fname);
if( outfile ) {
if( !(out = iobuf_create( outfile )) ) {
@ -1014,6 +1022,7 @@ int
sign_symencrypt_file (const char *fname, STRLIST locusr)
{
armor_filter_context_t afx;
progress_filter_context_t pfx;
compress_filter_context_t zfx;
md_filter_context_t mfx;
text_filter_context_t tfx;
@ -1049,6 +1058,7 @@ sign_symencrypt_file (const char *fname, STRLIST locusr)
rc = G10ERR_OPEN_FILE;
goto leave;
}
handle_progress (&pfx, inp, fname);
/* prepare key */
s2k = m_alloc_clear( sizeof *s2k );