diff options
Diffstat (limited to 'firmware/target/hosted/sonynwz')
-rw-r--r-- | firmware/target/hosted/sonynwz/button-nwz.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/firmware/target/hosted/sonynwz/button-nwz.c b/firmware/target/hosted/sonynwz/button-nwz.c index 2fb23e1471..f85a4be496 100644 --- a/firmware/target/hosted/sonynwz/button-nwz.c +++ b/firmware/target/hosted/sonynwz/button-nwz.c | |||
@@ -156,7 +156,7 @@ static void key_init_state(int fd) | |||
156 | 156 | ||
157 | static void open_input_device(const char *path) | 157 | static void open_input_device(const char *path) |
158 | { | 158 | { |
159 | int fd = open(path, O_RDWR); | 159 | int fd = open(path, O_RDONLY | O_CLOEXEC); |
160 | if(fd < 0) | 160 | if(fd < 0) |
161 | return; | 161 | return; |
162 | /* query name */ | 162 | /* query name */ |