return;
}
- log_info("Created new image %s.", p);
+ log_info("Created new local image %s.", p);
}
dkr_import_finish(name->import, 0);
if (curl_easy_getinfo(curl, CURLINFO_PRIVATE, &job) != CURLE_OK)
return;
- if (!job)
+ if (!job || job->done)
return;
job->done = true;
goto fail;
}
- r = btrfs_subvol_read_only(job->temp_path, true);
+ r = btrfs_subvol_set_read_only(job->temp_path, true);
if (r < 0) {
log_error_errno(r, "Failed to mark snapshot read-only: %m");
goto fail;
assert(contents);
assert(j);
+ if (j->done) {
+ r = -ESTALE;
+ goto fail;
+ }
+
if (j->tar_stream) {
size_t l;
assert(contents);
assert(j);
+ if (j->done) {
+ r = -ESTALE;
+ goto fail;
+ }
+
r = curl_header_strdup(contents, sz, HEADER_TOKEN, &token);
if (r < 0) {
log_oom();