summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--daemon/gvfsbackendafc.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/daemon/gvfsbackendafc.c b/daemon/gvfsbackendafc.c
index e1773d8c..11cd00c2 100644
--- a/daemon/gvfsbackendafc.c
+++ b/daemon/gvfsbackendafc.c
@@ -157,7 +157,7 @@ g_vfs_backend_afc_close_connection (GVfsBackendAfc *self)
{
afc_client_free (self->afc_cli);
}
- else
+ else if (self->mode == ACCESS_MODE_HOUSE_ARREST)
{
if (self->apps != NULL)
{
@@ -176,6 +176,10 @@ g_vfs_backend_afc_close_connection (GVfsBackendAfc *self)
}
g_mutex_clear (&self->apps_lock);
}
+ else
+ {
+ g_assert_not_reached ();
+ }
g_free (self->model);
self->model = NULL;
idevice_free (self->dev);
@@ -1835,7 +1839,7 @@ g_vfs_backend_afc_enumerate (GVfsBackend *backend,
return;
}
}
- else
+ else if (self->mode == ACCESS_MODE_HOUSE_ARREST)
{
char *app;
@@ -1890,6 +1894,10 @@ g_vfs_backend_afc_enumerate (GVfsBackend *backend,
}
}
}
+ else
+ {
+ g_assert_not_reached ();
+ }
trailing_slash = g_str_has_suffix (new_path ? new_path : path, "/");
@@ -1955,7 +1963,7 @@ g_vfs_backend_afc_query_info (GVfsBackend *backend,
return;
}
}
- else
+ else if (self->mode == ACCESS_MODE_HOUSE_ARREST)
{
char *app;
gboolean is_doc_root;
@@ -2004,6 +2012,10 @@ g_vfs_backend_afc_query_info (GVfsBackend *backend,
}
}
}
+ else
+ {
+ g_assert_not_reached ();
+ }
ptr = strrchr (new_path ? new_path : path, '/');
if (ptr && ptr[1] != '\0')