Skip to content

Commit

Permalink
OS-3689 lxbrand yorick interpreter spins on ^D
Browse files Browse the repository at this point in the history
  • Loading branch information
pfmooney committed Jan 8, 2015
1 parent 375a35b commit d9e1701
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions usr/src/lib/brand/lx/lx_brand/common/poll_select.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/

/*
* Copyright (c) 2014, Joyent, Inc. All rights reserved.
* Copyright (c) 2015, Joyent, Inc. All rights reserved.
*/

#include <assert.h>
Expand Down Expand Up @@ -150,9 +150,10 @@ lx_poll(uintptr_t p1, uintptr_t p2, uintptr_t p3)
int fds_size, i, rval, revents;

/*
* Deal with the NULL fds[] case.
* Little emulation is needed if nfds == 0.
* If p1 happens to be NULL, it'll be dealt with later.
*/
if (nfds == 0 && p1 == NULL) {
if (nfds == 0) {
if ((rval = poll(NULL, 0, (int)p3)) < 0)
return (-errno);

Expand Down

0 comments on commit d9e1701

Please sign in to comment.