summaryrefslogtreecommitdiff
path: root/src/import/import-dkr.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-12-24 16:42:41 +0100
committerLennart Poettering <lennart@poettering.net>2014-12-24 16:53:05 +0100
commit14ed8b9273690b82fed2d437f58e9e01487e9f69 (patch)
tree3faad7a471e4ee169844b3c9f76b6a99cea4d531 /src/import/import-dkr.c
parentea1ae8c38e669351b909cf8cc0c1e6fd140c1b58 (diff)
import: remember when we were finished importing
Diffstat (limited to 'src/import/import-dkr.c')
-rw-r--r--src/import/import-dkr.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/import/import-dkr.c b/src/import/import-dkr.c
index 594da547f5..e7dbe0f662 100644
--- a/src/import/import-dkr.c
+++ b/src/import/import-dkr.c
@@ -100,6 +100,8 @@ struct DkrImport {
dkr_import_on_finished on_finished;
void *userdata;
+
+ bool finished;
};
#define PROTOCOL_PREFIX "https://"
@@ -181,6 +183,11 @@ DEFINE_TRIVIAL_CLEANUP_FUNC(DkrImportName*, dkr_import_name_unref);
static void dkr_import_finish(DkrImport *import, int error) {
assert(import);
+ if (import->finished)
+ return;
+
+ import->finished = true;
+
if (import->on_finished)
import->on_finished(import, error, import->userdata);
else