summaryrefslogtreecommitdiff
path: root/src/import
diff options
context:
space:
mode:
Diffstat (limited to 'src/import')
-rw-r--r--src/import/export-raw.c2
-rw-r--r--src/import/export-tar.c2
-rw-r--r--src/import/export.c12
-rw-r--r--src/import/import-raw.c4
-rw-r--r--src/import/import-tar.c2
-rw-r--r--src/import/import.c12
-rw-r--r--src/import/importd.c2
-rw-r--r--src/import/pull-dkr.c2
-rw-r--r--src/import/pull-raw.c6
-rw-r--r--src/import/pull-tar.c2
-rw-r--r--src/import/pull.c18
11 files changed, 32 insertions, 32 deletions
diff --git a/src/import/export-raw.c b/src/import/export-raw.c
index 4b6d8dac32..8f9c9bbc80 100644
--- a/src/import/export-raw.c
+++ b/src/import/export-raw.c
@@ -265,7 +265,7 @@ static int reflink_snapshot(int fd, const char *path) {
if (new_fd < 0) {
_cleanup_free_ char *t = NULL;
- r = tempfn_random(path, &t);
+ r = tempfn_random(path, NULL, &t);
if (r < 0)
return r;
diff --git a/src/import/export-tar.c b/src/import/export-tar.c
index d31295745f..5adc748c50 100644
--- a/src/import/export-tar.c
+++ b/src/import/export-tar.c
@@ -290,7 +290,7 @@ int tar_export_start(TarExport *e, const char *path, int fd, ImportCompressType
free(e->temp_path);
e->temp_path = NULL;
- r = tempfn_random(path, &e->temp_path);
+ r = tempfn_random(path, NULL, &e->temp_path);
if (r < 0)
return r;
diff --git a/src/import/export.c b/src/import/export.c
index e563bee96e..ec7dbe210a 100644
--- a/src/import/export.c
+++ b/src/import/export.c
@@ -118,9 +118,9 @@ static int export_tar(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = tar_export_new(&export, event, on_tar_finished, event);
if (r < 0)
@@ -197,9 +197,9 @@ static int export_raw(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = raw_export_new(&export, event, on_raw_finished, event);
if (r < 0)
diff --git a/src/import/import-raw.c b/src/import/import-raw.c
index 97e1254f09..43cd413042 100644
--- a/src/import/import-raw.c
+++ b/src/import/import-raw.c
@@ -180,7 +180,7 @@ static int raw_import_maybe_convert_qcow2(RawImport *i) {
return 0;
/* This is a QCOW2 image, let's convert it */
- r = tempfn_random(i->final_path, &t);
+ r = tempfn_random(i->final_path, NULL, &t);
if (r < 0)
return log_oom();
@@ -267,7 +267,7 @@ static int raw_import_open_disk(RawImport *i) {
if (!i->final_path)
return log_oom();
- r = tempfn_random(i->final_path, &i->temp_path);
+ r = tempfn_random(i->final_path, NULL, &i->temp_path);
if (r < 0)
return log_oom();
diff --git a/src/import/import-tar.c b/src/import/import-tar.c
index 12701bfcef..2bf0b0680c 100644
--- a/src/import/import-tar.c
+++ b/src/import/import-tar.c
@@ -223,7 +223,7 @@ static int tar_import_fork_tar(TarImport *i) {
if (!i->final_path)
return log_oom();
- r = tempfn_random(i->final_path, &i->temp_path);
+ r = tempfn_random(i->final_path, NULL, &i->temp_path);
if (r < 0)
return log_oom();
diff --git a/src/import/import.c b/src/import/import.c
index 3091ed1c45..b7772390e9 100644
--- a/src/import/import.c
+++ b/src/import/import.c
@@ -116,9 +116,9 @@ static int import_tar(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = tar_import_new(&import, event, arg_image_root, on_tar_finished, event);
if (r < 0)
@@ -211,9 +211,9 @@ static int import_raw(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = raw_import_new(&import, event, arg_image_root, on_raw_finished, event);
if (r < 0)
diff --git a/src/import/importd.c b/src/import/importd.c
index 05a619ac0c..03aede6016 100644
--- a/src/import/importd.c
+++ b/src/import/importd.c
@@ -1301,7 +1301,7 @@ int main(int argc, char *argv[]) {
goto finish;
}
- assert_se(sigprocmask_many(SIG_BLOCK, SIGCHLD, -1) >= 0);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGCHLD, -1) >= 0);
r = manager_new(&m);
if (r < 0) {
diff --git a/src/import/pull-dkr.c b/src/import/pull-dkr.c
index d7476dc340..78e3184c42 100644
--- a/src/import/pull-dkr.c
+++ b/src/import/pull-dkr.c
@@ -520,7 +520,7 @@ static int dkr_pull_job_on_open_disk(PullJob *j) {
assert(!i->temp_path);
assert(i->tar_pid <= 0);
- r = tempfn_random(i->final_path, &i->temp_path);
+ r = tempfn_random(i->final_path, NULL, &i->temp_path);
if (r < 0)
return log_oom();
diff --git a/src/import/pull-raw.c b/src/import/pull-raw.c
index b65bb0c034..5bfaf012c0 100644
--- a/src/import/pull-raw.c
+++ b/src/import/pull-raw.c
@@ -208,7 +208,7 @@ static int raw_pull_maybe_convert_qcow2(RawPull *i) {
return 0;
/* This is a QCOW2 image, let's convert it */
- r = tempfn_random(i->final_path, &t);
+ r = tempfn_random(i->final_path, NULL, &t);
if (r < 0)
return log_oom();
@@ -280,7 +280,7 @@ static int raw_pull_make_local_copy(RawPull *i) {
if (i->force_local)
(void) rm_rf(p, REMOVE_ROOT|REMOVE_PHYSICAL|REMOVE_SUBVOLUME);
- r = tempfn_random(p, &tp);
+ r = tempfn_random(p, NULL, &tp);
if (r < 0)
return log_oom();
@@ -424,7 +424,7 @@ static int raw_pull_job_on_open_disk(PullJob *j) {
if (r < 0)
return log_oom();
- r = tempfn_random(i->final_path, &i->temp_path);
+ r = tempfn_random(i->final_path, NULL, &i->temp_path);
if (r < 0)
return log_oom();
diff --git a/src/import/pull-tar.c b/src/import/pull-tar.c
index 27a9af804d..a6605d248f 100644
--- a/src/import/pull-tar.c
+++ b/src/import/pull-tar.c
@@ -324,7 +324,7 @@ static int tar_pull_job_on_open_disk(PullJob *j) {
if (r < 0)
return log_oom();
- r = tempfn_random(i->final_path, &i->temp_path);
+ r = tempfn_random(i->final_path, NULL, &i->temp_path);
if (r < 0)
return log_oom();
diff --git a/src/import/pull.c b/src/import/pull.c
index 03fe3dcaf4..ca33d2f3fa 100644
--- a/src/import/pull.c
+++ b/src/import/pull.c
@@ -109,9 +109,9 @@ static int pull_tar(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = tar_pull_new(&pull, event, arg_image_root, on_tar_finished, event);
if (r < 0)
@@ -195,9 +195,9 @@ static int pull_raw(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = raw_pull_new(&pull, event, arg_image_root, on_raw_finished, event);
if (r < 0)
@@ -303,9 +303,9 @@ static int pull_dkr(int argc, char *argv[], void *userdata) {
if (r < 0)
return log_error_errno(r, "Failed to allocate event loop: %m");
- assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
- sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
- sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
+ assert_se(sigprocmask_many(SIG_BLOCK, NULL, SIGTERM, SIGINT, -1) >= 0);
+ (void) sd_event_add_signal(event, NULL, SIGTERM, interrupt_signal_handler, NULL);
+ (void) sd_event_add_signal(event, NULL, SIGINT, interrupt_signal_handler, NULL);
r = dkr_pull_new(&pull, event, arg_dkr_index_url, arg_image_root, on_dkr_finished, event);
if (r < 0)