ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libev/ev.c
(Generate patch)

Comparing libev/ev.c (file contents):
Revision 1.371 by root, Mon Feb 7 21:45:32 2011 UTC vs.
Revision 1.372 by root, Wed Feb 16 08:02:50 2011 UTC

4 * Copyright (c) 2007,2008,2009,2010,2011 Marc Alexander Lehmann <libev@schmorp.de> 4 * Copyright (c) 2007,2008,2009,2010,2011 Marc Alexander Lehmann <libev@schmorp.de>
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without modifica- 7 * Redistribution and use in source and binary forms, with or without modifica-
8 * tion, are permitted provided that the following conditions are met: 8 * tion, are permitted provided that the following conditions are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright notice, 10 * 1. Redistributions of source code must retain the above copyright notice,
11 * this list of conditions and the following disclaimer. 11 * this list of conditions and the following disclaimer.
12 * 12 *
13 * 2. Redistributions in binary form must reproduce the above copyright 13 * 2. Redistributions in binary form must reproduce the above copyright
14 * notice, this list of conditions and the following disclaimer in the 14 * notice, this list of conditions and the following disclaimer in the
15 * documentation and/or other materials provided with the distribution. 15 * documentation and/or other materials provided with the distribution.
16 * 16 *
17 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED 17 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
18 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MER- 18 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MER-
19 * CHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 19 * CHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
20 * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPE- 20 * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPE-
21 * CIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 21 * CIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
1369 read (evpipe [0], &dummy, 1); 1369 read (evpipe [0], &dummy, 1);
1370 } 1370 }
1371 1371
1372#if EV_SIGNAL_ENABLE 1372#if EV_SIGNAL_ENABLE
1373 if (sig_pending) 1373 if (sig_pending)
1374 { 1374 {
1375 sig_pending = 0; 1375 sig_pending = 0;
1376 1376
1377 for (i = EV_NSIG - 1; i--; ) 1377 for (i = EV_NSIG - 1; i--; )
1378 if (expect_false (signals [i].pending)) 1378 if (expect_false (signals [i].pending))
1379 ev_feed_signal_event (EV_A_ i + 1); 1379 ev_feed_signal_event (EV_A_ i + 1);
3078 if (!pend || pend == path) 3078 if (!pend || pend == path)
3079 break; 3079 break;
3080 3080
3081 *pend = 0; 3081 *pend = 0;
3082 w->wd = inotify_add_watch (fs_fd, path, mask); 3082 w->wd = inotify_add_watch (fs_fd, path, mask);
3083 } 3083 }
3084 while (w->wd < 0 && (errno == ENOENT || errno == EACCES)); 3084 while (w->wd < 0 && (errno == ENOENT || errno == EACCES));
3085 } 3085 }
3086 } 3086 }
3087 3087
3088 if (w->wd >= 0) 3088 if (w->wd >= 0)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines