Avoid non-standard conditionals with omitted operands.
[fw/openocd] / src / helper / command.c
index 43c5a0ffb7ee7f6452bebd164b47ac5e410bb5c5..4be3abd74a37e6578910fdd98733b970fcba086f 100644 (file)
@@ -866,9 +866,9 @@ static COMMAND_HELPER(command_help_show, struct help_entry *c,
                                        stage_msg = " (?mode error?)";
                                        break;
                        }
-                       msg = alloc_printf("%s%s", c->help ? : "", stage_msg);
+                       msg = alloc_printf("%s%s", c->help ? c->help : "", stage_msg);
                } else
-                       msg = alloc_printf("%s", c->help ? : "");
+                       msg = alloc_printf("%s", c->help ? c->help : "");
 
                if (NULL != msg) {
                        command_help_show_wrap(msg, n + 3, n + 3);