mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* win32/win32.c (set_pioinfo_extra): use MSVCRT's open() and close().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18906 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2fcd15d45d
commit
9f31706636
2 changed files with 6 additions and 2 deletions
|
@ -1,3 +1,7 @@
|
|||
Fri Aug 29 00:19:54 2008 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* win32/win32.c (set_pioinfo_extra): use MSVCRT's open() and close().
|
||||
|
||||
Fri Aug 29 00:03:13 2008 Yusuke Endoh <mame@tsg.ne.jp>
|
||||
|
||||
* file.c (file_expand_path): check invalid access.
|
||||
|
|
|
@ -1715,13 +1715,13 @@ set_pioinfo_extra(void)
|
|||
{
|
||||
int fd;
|
||||
|
||||
fd = open("NUL", O_RDONLY);
|
||||
fd = _open("NUL", O_RDONLY);
|
||||
for (pioinfo_extra = 0; pioinfo_extra <= 64; pioinfo_extra += sizeof(void *)) {
|
||||
if (_osfhnd(fd) == _get_osfhandle(fd)) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
close(fd);
|
||||
_close(fd);
|
||||
|
||||
if (pioinfo_extra > 64) {
|
||||
/* not found, maybe something wrong... */
|
||||
|
|
Loading…
Reference in a new issue