From: Steven Luo Date: Tue, 16 Feb 2010 02:50:01 +0000 (-0800) Subject: Clarify control flow in inotify read loop X-Git-Tag: v3.2~16 X-Git-Url: http://git.maemo.org/git/?p=browser-switch;a=commitdiff_plain;h=13c579741f0f3186a7b4fe5609607d7ac1aa984f;ds=sidebyside Clarify control flow in inotify read loop Replace pointer arithmetic that makes the loop condition false with a simple break; functionally equivalent, but much clearer. --- diff --git a/launcher.c b/launcher.c index 45ce750..9d2953b 100644 --- a/launcher.c +++ b/launcher.c @@ -381,7 +381,7 @@ void launch_microb(struct swb_context *ctx, char *uri) { pos += len; else /* All events processed */ - pos = buf + bytes_read; + break; } if (!pos) /* Event found, stop looking */