forked from drath/libratbag
ratbagd: fix use of potentially unused variable
Simply abort if the macro value is bad, that's a libratbag bug and should never happen. Found in #312 Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
committed by
Benjamin Tissoires
parent
c868c43179
commit
6cdf8a901a
@@ -305,6 +305,8 @@ static int ratbagd_button_get_macro(sd_bus *bus,
|
||||
case RATBAG_MACRO_EVENT_WAIT:
|
||||
value = ratbag_button_macro_get_event_timeout(macro, idx);
|
||||
break;
|
||||
default:
|
||||
abort();
|
||||
}
|
||||
|
||||
r = sd_bus_message_append(reply, "(uu)", type, value);
|
||||
|
||||
Reference in New Issue
Block a user