Home GnuPG
Diffusion GnuPG 6da7aa1e7c80

gpg,w32: Fix empty homedir when only a drive letter is used.

Description

gpg,w32: Fix empty homedir when only a drive letter is used.

* common/homedir.c (copy_dir_with_fixup): New.
(default_homedir): Use here.
(gnupg_set_homedir): And here .

This actually fixes a couple of cases for Windows. Both --home-dir
and GNUPGHOME. The interpretation of "c:" -> "c:/" might not be the
correct one but because we need an absolute dir anyway it is the less
surprising one. Note that this does not include a full syntax check
and fixup and thus it is very well possible that the result is not an
absolute directory.

  • GnuPG-bug-id: T3720
  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details