X-Git-Url: https://sigrok.org/gitweb/?p=sigrok-cli.git;a=blobdiff_plain;f=anykey.c;h=24970c2c299a26733dc754a34a3c586925367be5;hp=478e644c31edb156678bc36a6c73f76081442581;hb=b6479f7df73a0933bc364dcd61ae45955d826bf1;hpb=8170b8eaefadcd4e572d96da2de0dbdbfe7ee131 diff --git a/anykey.c b/anykey.c index 478e644..24970c2 100644 --- a/anykey.c +++ b/anykey.c @@ -1,5 +1,5 @@ /* - * This file is part of the sigrok project. + * This file is part of the sigrok-cli project. * * Copyright (C) 2011 Bert Vermeulen * @@ -26,7 +26,7 @@ #include #include #include -#include +#include #include "sigrok-cli.h" #ifdef _WIN32 @@ -38,11 +38,11 @@ static struct termios term_orig; static int received_anykey(int fd, int revents, void *cb_data) { - /* Avoid compiler warnings. */ (void)fd; (void)revents; (void)cb_data; + sr_session_source_remove(STDIN_FILENO); sr_session_stop(); return TRUE;