... needed at least for gdb ...
Signed-off-by: Daniel Lezcano <[email protected]>
---
powerdebug.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/powerdebug.c b/powerdebug.c
index 7d89a7b..8e7e78e 100644
--- a/powerdebug.c
+++ b/powerdebug.c
@@ -288,10 +288,17 @@ int mainloop(struct powerdebug_options *options,
tval.tv_sec = options->ticktime;
tval.tv_usec = (options->ticktime - tval.tv_sec) * 1000000;
+ again:
key = select(1, &readfds, NULL, NULL, &tval);
if (!key)
continue;
+ if (key < 0) {
+ if (errno == EINTR)
+ goto again;
+ break;
+ }
+
if (keystroke_callback(&enter_hit, &findparent_ncurses,
clkname_str, &refreshwin, options))
break;
--
1.7.1
_______________________________________________
linaro-dev mailing list
[email protected]
http://lists.linaro.org/mailman/listinfo/linaro-dev