mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* io.c (linux_get_maxfd): get rid of a warning.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33806 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f49f6ff1d7
commit
08f8dfc20b
2 changed files with 5 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
Tue Nov 22 00:25:17 2011 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
|
* io.c (linux_get_maxfd): get rid of a warning.
|
||||||
|
|
||||||
Mon Nov 21 23:39:14 2011 Tanaka Akira <akr@fsij.org>
|
Mon Nov 21 23:39:14 2011 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
* io.c (linux_get_maxfd): new function to find maximum fd on Linux.
|
* io.c (linux_get_maxfd): new function to find maximum fd on Linux.
|
||||||
|
|
2
io.c
2
io.c
|
@ -5153,7 +5153,7 @@ linux_get_maxfd(void)
|
||||||
if (ss == -1) goto err;
|
if (ss == -1) goto err;
|
||||||
p = buf;
|
p = buf;
|
||||||
e = buf + ss;
|
e = buf + ss;
|
||||||
while (sizeof("FDSize:\t0\n")-1 <= e-p &&
|
while ((int)sizeof("FDSize:\t0\n")-1 <= e-p &&
|
||||||
(n = memchr(p, '\n', e-p)) != NULL) {
|
(n = memchr(p, '\n', e-p)) != NULL) {
|
||||||
if (memcmp(p, "FDSize:", sizeof("FDSize:")-1) == 0) {
|
if (memcmp(p, "FDSize:", sizeof("FDSize:")-1) == 0) {
|
||||||
int fdsize;
|
int fdsize;
|
||||||
|
|
Loading…
Reference in a new issue