aboutsummaryrefslogtreecommitdiffstats
path: root/core/git-access.c
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-01-12 23:55:34 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-01-19 09:45:08 +0200
commit0b0eacce30fb945e97383405bec61fea5ca84afc (patch)
tree97d39a238979f085f3c11072f75dbf337d4c90d7 /core/git-access.c
parentb188f005878458dfeb875fd40b26ebf9d37b655b (diff)
downloadsubsurface-0b0eacce30fb945e97383405bec61fea5ca84afc.tar.gz
Check cloudserver availability only for cloud repositories
The check used to be done for any https:// repository. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/git-access.c')
-rw-r--r--core/git-access.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/git-access.c b/core/git-access.c
index 864516e41..13996fbbe 100644
--- a/core/git-access.c
+++ b/core/git-access.c
@@ -586,7 +586,7 @@ int sync_with_remote(git_repository *repo, const char *remote, const char *branc
return 0;
}
- if (rt == RT_HTTPS && !canReachCloudServer()) {
+ if (is_subsurface_cloud && !canReachCloudServer()) {
// this is not an error, just a warning message, so return 0
report_error("Cannot connect to cloud server, working with local copy");
git_storage_update_progress(translate("gettextFromC", "Can't reach cloud server, working with local data"));
@@ -732,7 +732,7 @@ static git_repository *create_local_repo(const char *localdir, const char *remot
opts.fetch_opts.callbacks.certificate_check = certificate_check_cb;
opts.checkout_branch = branch;
- if (rt == RT_HTTPS && !canReachCloudServer())
+ if (is_subsurface_cloud && !canReachCloudServer())
return 0;
if (verbose > 1)
fprintf(stderr, "git storage: calling git_clone()\n");