mirror of
https://github.com/NixOS/nix.git
synced 2025-04-16 14:19:21 +00:00
monitor-fd.hh
: Format
It's a pretty small diff, so let's just start formatting before we make
other changes.
(cherry picked from commit 041394b741
)
This commit is contained in:
parent
b369ccf1d7
commit
a04bc3ed7a
@ -368,7 +368,6 @@
|
||||
''^src/libutil/types\.hh$''
|
||||
''^src/libutil/unix/file-descriptor\.cc$''
|
||||
''^src/libutil/unix/file-path\.cc$''
|
||||
''^src/libutil/unix/monitor-fd\.hh$''
|
||||
''^src/libutil/unix/processes\.cc$''
|
||||
''^src/libutil/unix/signals-impl\.hh$''
|
||||
''^src/libutil/unix/signals\.cc$''
|
||||
|
@ -14,7 +14,6 @@
|
||||
|
||||
namespace nix {
|
||||
|
||||
|
||||
class MonitorFdHup
|
||||
{
|
||||
private:
|
||||
@ -33,11 +32,11 @@ public:
|
||||
anymore. So wait for read events and ignore
|
||||
them. */
|
||||
fds[0].events =
|
||||
#ifdef __APPLE__
|
||||
#ifdef __APPLE__
|
||||
POLLRDNORM
|
||||
#else
|
||||
#else
|
||||
0
|
||||
#endif
|
||||
#endif
|
||||
;
|
||||
auto count = poll(fds, 1, -1);
|
||||
if (count == -1)
|
||||
@ -50,7 +49,8 @@ public:
|
||||
coordination with the main thread if spinning proves
|
||||
too harmful.
|
||||
*/
|
||||
if (count == 0) continue;
|
||||
if (count == 0)
|
||||
continue;
|
||||
if (fds[0].revents & POLLHUP) {
|
||||
unix::triggerInterrupt();
|
||||
break;
|
||||
@ -70,5 +70,4 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user