mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* win32/win32.c (rb_w32_strerror): remove all CR and LF. (avoid broken
error message on bccwin32 + winsock) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9625 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1e85f16423
commit
c43a23d49e
2 changed files with 8 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
Mon Nov 28 13:11:45 2005 Hirokazu Yamamoto <ocean@m2.ccsnet.ne.jp>
|
||||||
|
|
||||||
|
* win32/win32.c (rb_w32_strerror): remove all CR and LF. (avoid broken
|
||||||
|
error message on bccwin32 + winsock)
|
||||||
|
|
||||||
Mon Nov 28 09:15:50 2005 Hirokazu Yamamoto <ocean@m2.ccsnet.ne.jp>
|
Mon Nov 28 09:15:50 2005 Hirokazu Yamamoto <ocean@m2.ccsnet.ne.jp>
|
||||||
|
|
||||||
* lib/mkmf.rb (create_makefile): should not change sodir with
|
* lib/mkmf.rb (create_makefile): should not change sodir with
|
||||||
|
|
|
@ -1759,9 +1759,9 @@ rb_w32_strerror(int e)
|
||||||
buffer[sizeof(buffer) - 1] = 0;
|
buffer[sizeof(buffer) - 1] = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (p = buffer + strlen(buffer) - 1; buffer <= p; p--) {
|
p = buffer;
|
||||||
if (*p != '\r' && *p != '\n') break;
|
while ((p = strpbrk(p, "\r\n")) != NULL) {
|
||||||
*p = 0;
|
memmove(p, p + 1, strlen(p));
|
||||||
}
|
}
|
||||||
return buffer;
|
return buffer;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue