chiark / gitweb /
fix gcc warnings about uninitialized variables
[elogind.git] / src / journal / coredump.c
index 6357d3e277295b3fde0f95ea24f9984cd386c152..4e23e487fbbe55d735f22f8a5173ec261edab350 100644 (file)
@@ -242,7 +242,7 @@ static int maybe_remove_external_coredump(const char *filename, off_t size) {
 
 static int make_filename(const char *info[_INFO_LEN], char **ret) {
         _cleanup_free_ char *c = NULL, *u = NULL, *p = NULL, *t = NULL;
-        sd_id128_t boot;
+        sd_id128_t boot = {};
         int r;
 
         assert(info);
@@ -841,7 +841,7 @@ log:
         /* Optionally store the entire coredump in the journal */
         if (IN_SET(arg_storage, COREDUMP_STORAGE_JOURNAL, COREDUMP_STORAGE_BOTH) &&
             coredump_size <= (off_t) arg_journal_size_max) {
-                size_t sz;
+                size_t sz = 0;
 
                 /* Store the coredump itself in the journal */