summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Withnall <withnall@endlessm.com>2019-10-28 19:40:26 +0000
committerPhilip Withnall <withnall@endlessm.com>2019-10-28 20:17:07 +0000
commit9df8d76c972de7cad6e62f7fbdda043ce86b8cc7 (patch)
tree6df64e355f32bae129a37745a0113ec3de221c15
parentef3eec8a2876691a71574d871668283ae8d379b7 (diff)
downloadglib-9df8d76c972de7cad6e62f7fbdda043ce86b8cc7.tar.gz
gdbusauthmechanismsha1: Create .dbus-keyrings directory recursively
If the directory is overridden, for example when running tests, the parent directory of `.dbus-keyrings` (i.e. the fake `$HOME` directory) might not exist. Create it automatically. This should realistically not have an effect on non-test code. Signed-off-by: Philip Withnall <withnall@endlessm.com> Helps: #1912
-rw-r--r--gio/gdbusauthmechanismsha1.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gio/gdbusauthmechanismsha1.c b/gio/gdbusauthmechanismsha1.c
index d29048ad7..2754d3c2b 100644
--- a/gio/gdbusauthmechanismsha1.c
+++ b/gio/gdbusauthmechanismsha1.c
@@ -292,7 +292,7 @@ ensure_keyring_directory (GError **error)
goto out;
}
- if (g_mkdir (path, 0700) != 0)
+ if (g_mkdir_with_parents (path, 0700) != 0)
{
int errsv = errno;
g_set_error (error,