Skip to content

Instantly share code, notes, and snippets.

@anttikantee
Created July 18, 2013 06:06
Show Gist options
  • Save anttikantee/6027029 to your computer and use it in GitHub Desktop.
Save anttikantee/6027029 to your computer and use it in GitHub Desktop.
Index: rumpuser_sp.c
===================================================================
RCS file: /cvsroot/src/lib/librumpuser/rumpuser_sp.c,v
retrieving revision 1.58
diff -u -r1.58 rumpuser_sp.c
--- rumpuser_sp.c 30 Apr 2013 12:39:20 -0000 1.58
+++ rumpuser_sp.c 18 Jul 2013 06:02:13 -0000
@@ -647,8 +647,9 @@
if (pfdlist[i].fd == -1 && spclist[i].spc_state == SPCSTATE_NEW)
break;
}
-
assert(i < MAXCLI);
+ if (i == MAXCLI)
+ return -1;
pfdlist[i].fd = newfd;
spclist[i].spc_fd = newfd;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment