projects
/
platform
/
upstream
/
libwebsockets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
40110e8
)
Refactoring conditional directives for if wrappers
author
wmarquesr
<wesleymr.27@gmail.com>
Sun, 13 Dec 2015 23:36:41 +0000
(20:36 -0300)
committer
Andy Green
<andy.green@linaro.org>
Mon, 14 Dec 2015 01:39:56 +0000
(09:39 +0800)
lib/pollfd.c
patch
|
blob
|
history
diff --git
a/lib/pollfd.c
b/lib/pollfd.c
index
c37317c
..
03725e0
100644
(file)
--- a/
lib/pollfd.c
+++ b/
lib/pollfd.c
@@
-137,6
+137,7
@@
lws_change_pollfd(struct lws *wsi, int _and, int _or)
int sampled_tid;
struct lws_pollfd *pfd;
struct lws_pollargs pa;
+ int pa_events = 1;
if (!wsi || !wsi->protocol || wsi->position_in_fds_table < 0)
return 1;
@@
-168,8
+169,9
@@
lws_change_pollfd(struct lws *wsi, int _and, int _or)
* then cancel it to force a restart with our changed events
*/
#if LWS_POSIX
- if (pa.prev_events != pa.events)
+ pa_events = (pa.prev_events != pa.events);
#endif
+ if (pa_events)
{
if (lws_plat_change_pollfd(context, wsi, pfd)) {