sm: Create homedir and lock empty keybox creation.
authorWerner Koch <wk@gnupg.org>
Thu, 14 Aug 2014 15:14:21 +0000 (17:14 +0200)
committerWerner Koch <wk@gnupg.org>
Thu, 14 Aug 2014 15:15:50 +0000 (17:15 +0200)
commitc4b60cdae8dbf68206fd105fd09adeb61a9dafe4
treee63d85f116ffdae27d76ff2bab4c32df9c323646
parent21e5125e441ee64fa2634d9de640cc57efe565cd
sm: Create homedir and lock empty keybox creation.

* sm/gpgsm.h (opt): Add field "no_homedir_creation".
* sm/gpgsm.c (main): Set it if --no-options is used.
* sm/keydb.c (try_make_homedir): New.  Similar to the one from
g10/openfile.c.
(maybe_create_keybox): New.  Similar to the one from g10/keydb.c.
(keydb_add_resource): Replace some code by maybe_create_keybox.
sm/gpgsm.c
sm/gpgsm.h
sm/keydb.c