diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2021-04-11 15:26:06 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2021-04-19 12:51:01 -0700 |
commit | cfe20ee5f4f77a3a42ba301bdd69f5585c46184c (patch) | |
tree | 54caed8f5dbbef0e557ec2b01a0667b709e76a5d /core/qthelper.h | |
parent | 7fa031b648fedeaa35eb4da8003cd521cf65c4e3 (diff) | |
download | subsurface-cfe20ee5f4f77a3a42ba301bdd69f5585c46184c.tar.gz |
cloudstorage: create consistent local directory names
With the new names for the cloud server we'd get different local cache
directory names depending on which server gets used. In order to avoid
that, normalize the name before generating the hash that determines the
local directory name.
Additionally, the old code had an extra '/' in the URL, due to the way
the URL was assembled. Again, to match the existing hash for people
upgrading from older Subsurface versions, add that to our normalized
name as well.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'core/qthelper.h')
-rw-r--r-- | core/qthelper.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/qthelper.h b/core/qthelper.h index 135689c69..1fc2e55f3 100644 --- a/core/qthelper.h +++ b/core/qthelper.h @@ -147,6 +147,7 @@ void copy_image_and_overwrite(const char *cfileName, const char *path, const cha char *move_away(const char *path); const char *local_file_path(struct picture *picture); char *cloud_url(); +const char *normalize_cloud_name(const char *remote_in); char *hashfile_name_string(); char *picturedir_string(); const char *subsurface_user_agent(); |