projects
/
browser-switch
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
3280115
)
Clarify control flow in inotify read loop
author
Steven Luo
<steven+maemo@steven676.net>
Tue, 16 Feb 2010 02:50:01 +0000
(18:50 -0800)
committer
Steven Luo
<steven+maemo@steven676.net>
Tue, 16 Feb 2010 02:50:01 +0000
(18:50 -0800)
Replace pointer arithmetic that makes the loop condition false with a
simple break; functionally equivalent, but much clearer.
launcher.c
patch
|
blob
|
history
diff --git
a/launcher.c
b/launcher.c
index
45ce750
..
9d2953b
100644
(file)
--- 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 */