diff options
author | Felix Fietkau <nbd@openwrt.org> | 2013-08-03 11:56:27 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2013-08-03 11:56:27 +0000 |
commit | 2c425944b0a9f0b92f1c5a2e4112fee01650c988 (patch) | |
tree | 6fb6b87e74ecf6a9ee2327f62e573514960efa64 /package/kernel | |
parent | 6d9f7bbe10a50a1ef2d2d1d39d162fdb2a474bcf (diff) | |
download | upstream-2c425944b0a9f0b92f1c5a2e4112fee01650c988.tar.gz upstream-2c425944b0a9f0b92f1c5a2e4112fee01650c988.tar.bz2 upstream-2c425944b0a9f0b92f1c5a2e4112fee01650c988.zip |
gpio-button-hotplug: cleanup, fix compiler warning
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37665 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/kernel')
-rw-r--r-- | package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c b/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c index 012cd228dc..487c813dda 100644 --- a/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c +++ b/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c @@ -128,6 +128,7 @@ static int bh_event_add_var(struct bh_event *event, int argv, static int button_hotplug_fill_event(struct bh_event *event) { + char *s; int ret; ret = bh_event_add_var(event, 0, "HOME=%s", "/"); @@ -139,14 +140,11 @@ static int button_hotplug_fill_event(struct bh_event *event) if (ret) return ret; - char *s; switch (event->type) { - case EV_KEY: - s = "button"; - break; case EV_SW: s = "switch"; break; + case EV_KEY: default: s = "button"; break; |