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

Print verbose instructions in case of a corrupted trustdb.

This commit is contained in:
Werner Koch 2009-07-22 09:43:10 +00:00
parent 12fa2baa62
commit 5d310a8de7
6 changed files with 35 additions and 8 deletions

View file

@ -407,6 +407,27 @@ setup_trustdb( int level, const char *dbname )
return 0;
}
void
how_to_fix_the_trustdb ()
{
const char *name = trustdb_args.dbname;
if (!name)
name = "trustdb.gpg";
log_info (_("You may try to re-create the trustdb using the commands:\n"));
log_info (" cd %s\n", default_homedir ());
log_info (" gpg2 --export-ownertrust > otrust.tmp\n");
#ifdef HAVE_W32_SYSTEM
log_info (" del %s\n", name);
#else
log_info (" rm %s\n", name);
#endif
log_info (" gpg2 --import-ownertrust < otrust.tmp\n");
log_info (_("If that does not work, please consult the manual\n"));
}
void
init_trustdb()
{