diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2015-10-13 10:32:33 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-10-13 10:32:33 -0700 |
commit | 50421f1fa8c6d999d13348a89527df7adcc02fd9 (patch) | |
tree | ba5bfa5d744a4e62fb6392294b65eecb27577484 /macos.c | |
parent | ec8f2176a7d565ab55c00bebe0f31ae83c368945 (diff) | |
download | subsurface-50421f1fa8c6d999d13348a89527df7adcc02fd9.tar.gz |
Make sure our default path exists (for Linux and Mac)
I'm not sure if this could ever turn into an issue on Windows - but on
Linux and Mac this is an easy and safe thing to do and it avoids a
situation where we try to save the picture hashes without having this
directory.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'macos.c')
-rw-r--r-- | macos.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -56,6 +56,8 @@ static const char *system_default_path_append(const char *append) memset(buffer, 0, len); strcat(buffer, home); strcat(buffer, path); + // make sure this path exists + subsurface_mkdir(buffer); if (append) { strcat(buffer, "/"); strcat(buffer, append); |