chiark / gitweb /
log: make sure generators never log into the journal to avoid activation deadlocks
[elogind.git] / src / cryptsetup / cryptsetup-generator.c
index edc28998b281a528159dcede2053ea4d1b1a09a6..7eb122d27618794ba52c4783450a26eac251c212 100644 (file)
@@ -112,6 +112,7 @@ static int create_disk(
         }
 
         fprintf(f,
+                "# Automatically generated by systemd-cryptsetup-generator\n\n"
                 "[Unit]\n"
                 "Description=Cryptography Setup for %%I\n"
                 "Conflicts=umount.target\n"
@@ -248,7 +249,7 @@ int main(int argc, char *argv[]) {
         if (argc > 1)
                 arg_dest = argv[1];
 
-        log_set_target(LOG_TARGET_AUTO);
+        log_set_target(LOG_TARGET_SAFE);
         log_parse_environment();
         log_open();