]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
coredump: fix style nits
authorLuca Boccassi <luca.boccassi@microsoft.com>
Wed, 7 Apr 2021 09:16:54 +0000 (10:16 +0100)
committerLuca Boccassi <luca.boccassi@microsoft.com>
Wed, 7 Apr 2021 13:02:38 +0000 (14:02 +0100)
Follow-up for 95f71807733

src/coredump/coredumpctl.c
src/coredump/stacktrace.c

index 3418753a31b3312d09108ba5eec01835f19cb74b..0ba218a39db04c68c698cceafb9a0a736f83a73b 100644 (file)
@@ -729,9 +729,9 @@ static int print_info(FILE *file, sd_journal *j, bool need_space) {
                 _cleanup_(json_variant_unrefp) JsonVariant *v = NULL;
 
                 r = json_parse(pkgmeta_json, 0, &v, NULL, NULL);
-                if (r < 0) {
+                if (r < 0)
                         log_warning_errno(r, "json_parse on %s failed, ignoring: %m", pkgmeta_json);
-                else {
+                else {
                         const char *module_name;
                         JsonVariant *module_json;
 
index cc31c7b03cf8a219430cb4764c3c9518b50e5c92..9cf2be33654ae18393651fddcdeeaa99daeb2096 100644 (file)
@@ -241,12 +241,12 @@ static int module_callback(Dwfl_Module *mod, void **userdata, const char *name,
          * The build-id is easy, as libdwfl parses it during the dwfl_core_file_report() call and
          * stores it separately in an internal library struct. */
         id_len = dwfl_module_build_id(mod, &id, &id_vaddr);
-        if (id_len <= 0) {
+        if (id_len <= 0)
                 /* If we don't find a build-id, note it in the journal message, and try
                  * anyway to find the package metadata. It's unlikely to have the latter
                  * without the former, but there's no hard rule. */
-                fprintf(c->f, "Found module %s without build-id\n", name);
-        else {
+                fprintf(c->f, "Found module %s without build-id.\n", name);
+        else {
                 _cleanup_free_ char *id_hex = NULL, *id_hex_prefixed = NULL;
 
                 id_hex = hexmem(id, id_len);