diff options
| author | Werner Koch <[email protected]> | 1998-12-29 18:58:27 +0000 |
|---|---|---|
| committer | Werner Koch <[email protected]> | 1998-12-29 18:58:27 +0000 |
| commit | d6fa538a957eb00507219d0bfa0ac96408355d04 (patch) | |
| tree | ccba0b2fb79fb91eeaf437b50bc1f415dcac605c /g10/trustdb.c | |
| parent | See ChangeLog: Tue Dec 29 14:41:47 CET 1998 Werner Koch (diff) | |
| download | gnupg-d6fa538a957eb00507219d0bfa0ac96408355d04.tar.gz gnupg-d6fa538a957eb00507219d0bfa0ac96408355d04.zip | |
See ChangeLog: Tue Dec 29 19:55:38 CET 1998 Werner Koch
Diffstat (limited to 'g10/trustdb.c')
| -rw-r--r-- | g10/trustdb.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/g10/trustdb.c b/g10/trustdb.c index cb5be1028..759720cd7 100644 --- a/g10/trustdb.c +++ b/g10/trustdb.c @@ -2939,9 +2939,18 @@ update_trust_record( KBNODE keyblock, int recheck, int *modified ) /* delete keyrecords from the trustdb which are not anymore used */ /* should we really do this, or is it better to keep them and */ /* mark as unused? */ + /* And set the revocation flag into the dir record */ + drec.r.dir.dirflags &= ~DIRF_REVOKED; lastrecno = 0; for( recno=drec.r.dir.keylist; recno; recno = krec.r.key.next ) { read_record( recno, &krec, RECTYPE_KEY ); + if( recno == drec.r.dir.keylist ) { /* this is the primary key */ + if( (krec.r.key.keyflags & KEYF_REVOKED) ) { + drec.r.dir.dirflags |= DIRF_REVOKED; + drec.dirty = 1; + } + } + if( !qry_recno_list( recno_list, recno, RECTYPE_KEY ) ) { /* delete this one */ if( !lastrecno ) { @@ -2994,11 +3003,11 @@ update_trust_record( KBNODE keyblock, int recheck, int *modified ) if( rc ) rc = tdbio_cancel_transaction(); else { + if( modified && tdbio_is_dirty() ) + *modified = 1; drec.r.dir.dirflags |= DIRF_CHECKED; drec.r.dir.dirflags &= ~DIRF_VALVALID; write_record( &drec ); - if( modified && tdbio_is_dirty() ) - *modified = 1; rc = tdbio_end_transaction(); } rel_recno_list( &recno_list ); |
