diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-09-09 04:35:43 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-09-09 04:35:43 +0200 |
commit | a288de65a6e59201a9a7295c49f0eb7be9023e90 (patch) | |
tree | afed5ae16a586265b3e3f7a38f8c59ebfe1c3383 | |
parent | never volatile int, always volatile sig_atomic_t (diff) | |
download | mds-a288de65a6e59201a9a7295c49f0eb7be9023e90.tar.gz mds-a288de65a6e59201a9a7295c49f0eb7be9023e90.tar.bz2 mds-a288de65a6e59201a9a7295c49f0eb7be9023e90.tar.xz |
m
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | src/mds-clipboard.c | 6 | ||||
-rw-r--r-- | src/mds-echo.c | 12 | ||||
-rw-r--r-- | src/mds-kkbd.c | 6 | ||||
-rw-r--r-- | src/mds-vt.c | 10 |
4 files changed, 11 insertions, 23 deletions
diff --git a/src/mds-clipboard.c b/src/mds-clipboard.c index d7a943f..55798a6 100644 --- a/src/mds-clipboard.c +++ b/src/mds-clipboard.c @@ -351,10 +351,8 @@ int master_loop(void) } if (r = mds_message_read(&received, socket_fd), r == 0) - { - if (r = handle_message(), r == 0) - continue; - } + if (r = handle_message(), r == 0) + continue; if (r == -2) { diff --git a/src/mds-echo.c b/src/mds-echo.c index b6df862..31e8b86 100644 --- a/src/mds-echo.c +++ b/src/mds-echo.c @@ -218,17 +218,13 @@ int __attribute__((const)) reexec_failure_recover(void) */ int master_loop(void) { - int rc = 1; + int rc = 1, r; while (!reexecing && !terminating) { - int r = mds_message_read(&received, socket_fd); - if (r == 0) - { - r = echo_message(); - if (r == 0) - continue; - } + if (r = mds_message_read(&received, socket_fd), r == 0) + if (r = echo_message(), r == 0) + continue; if (r == -2) { diff --git a/src/mds-kkbd.c b/src/mds-kkbd.c index f5c44b8..86290cd 100644 --- a/src/mds-kkbd.c +++ b/src/mds-kkbd.c @@ -432,10 +432,8 @@ int master_loop(void) } if (r = mds_message_read(&received, socket_fd), r == 0) - { - if (r = handle_message(), r == 0) - continue; - } + if (r = handle_message(), r == 0) + continue; if (r == -2) { diff --git a/src/mds-vt.c b/src/mds-vt.c index dd30b46..aa82d34 100644 --- a/src/mds-vt.c +++ b/src/mds-vt.c @@ -374,13 +374,9 @@ int master_loop(void) /* FIXME */ } - r = mds_message_read(&received, socket_fd); - if (r == 0) - { - r = 0; /* FIXME */ - if (r == 0) - continue; - } + if (r = mds_message_read(&received, socket_fd), r == 0) + if (r = 0, r == 0) /* FIXME */ + continue; if (r == -2) { |