aboutsummaryrefslogtreecommitdiffstats
path: root/win32/win32.c
Commit message (Collapse)AuthorAgeFilesLines
* * win32/win32.c (rb_w32_wopen): shouldn't use FILE_FLAG_OVERLAPPED withusa2010-04-221-3/+0
| | | | | | | normal file. #1807, #2510, #2549 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * include/ruby/win32.h: check definition existance before definingusa2010-04-061-2/+36
| | | | | | | | | | errno macros. * win32/win32.c (errmap): define winsock errors mappings. these are VC++10 support. see [ruby-core:29278] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * include/ruby/win32.h, win32/win32.c (EWOULDBLOCK): VC10 alreadyusa2010-04-051-1/+2
| | | | | | | | defined EWOULDBLOCK. based on a patch from Charlie Savage, see [ruby-core:29255] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27222 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (init_env): wrong calculation of the head of setenvusa2010-04-021-1/+1
| | | | | | | | string. [ruby-core:29216] a patch from Heesob Park in [ruby-core:29218] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_{read,write}): fix handle leaks. based onnobu2010-03-251-0/+2
| | | | | | a patch from Heesob Park in [ruby-core:28919]. [ruby-core:28833] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_read): limit read size to 16KB if the filenobu2010-03-241-2/+17
| | | | | | | seems to be console. [ruby-core:28902] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tmpdir: split from lib/tmpdir.rb.nobu2010-03-161-9/+18
| | | | | | | * win32/win32.c (rb_w32_system_tmpdir): extracted from init_env. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26952 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_getcwd): remvoed duplicated code.nobu2010-03-161-6/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26951 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (init_env): get rid of alloca() for outer string.nobu2010-03-111-11/+16
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26883 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (signbit): allow x64.wanabe2010-03-101-4/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * io.c (pipe_open): suppressed a warning.nobu2010-03-051-4/+5
| | | | | | | | | * win32/win32.c (rb_w32_map_errno, winnt_stat, rb_chsize): ditto. * win32/win32.c (rb_w32_aspawn): get rid of overflow. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26822 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (signbit): defined on mingw.nobu2010-03-051-0/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26820 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (signbig): defined.nobu2010-03-021-0/+11
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26799 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (init_env): use _wputenv() instead ofusa2010-01-121-3/+10
| | | | | | | | | SetEnvironmentVariableW() because latter doesn't set msvcrt's environ work area, of course. [Bug #2552] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26296 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (CreateChild): force to inherit standard I/O handles.usa2009-12-281-20/+18
| | | | | | | | this change fixes [ruby-core:27273], but other side effects might exist. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26192 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (overlapped_socket_io, recvmsg, sendmsg): pass handlewanabe2009-11-011-3/+3
| | | | | | instead of pointer to CloseHandle(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25611 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32.c (recvmsg, sendmsg, link): shouldn't raise ruby's exceptionsusa2009-10-301-5/+23
| | | | | | | | | in the functions expected as system API. see [ruby-dev:39579] and [ruby-dev:39582] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25569 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_spawn): `\'' is also quote character.usa2009-10-161-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25367 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/{setup.mak,Makefile.sub,win32.c},include/ruby/win32.h (RT_VER):usa2009-10-011-7/+4
| | | | | | | | | | | split compiler specification and runtime library specification. * win32/Makefile.sub (LD_SHARED*, config.status): no need to embbed manifest if not exist. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_getpid): simply call GetCurrentProcessId()usa2009-10-011-2/+1
| | | | | | | | instead of calling MSVCRT's getpid(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/wini32.c (LK_ERR): with overlapped I/O, LockFileEx() returnsusa2009-09-281-1/+1
| | | | | | | | ERROR_IO_PENDING if the file is locked. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25133 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c, include/ruby/win32.h (rb_w32_access): new function tousa2009-09-251-0/+14
| | | | | | | | | | | replace MSVCRT's access(). [ruby-core:25761] * file.c (eaccess): workaround for recent MSVCRT is no longer needed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (readdir_internal): free old temporary filename.usa2009-08-121-2/+4
| | | | | | | | [ruby-core:24820] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24510 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (has_redirection): need to execute shell if commandlineusa2009-08-041-2/+3
| | | | | | | | includes newline. cf. [ruby-core:24560] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_connect): return value was broken when someusa2009-08-031-7/+4
| | | | | | | | | error occurred. [ruby-core:24234] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24367 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_{open,wopen}): fixed typos. these conditionsusa2009-07-231-2/+2
| | | | | | | | mean to call runtime's open() if textmode. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24253 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (WSABUF): get rid of compile error on VC9 and mingw.usa2009-07-221-1/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24235 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.[ch] (recvmsg, sendmsg): new functions to support recvmsg/usa2009-07-211-1/+206
| | | | | | | | | sendmsg like UNIX. these functions are experimental and not tested well. bug reports are welcome. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24218 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_spawn): use original command if not found.nobu2009-03-231-2/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23036 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_spawn, rb_w32_aspawn): use NULL asnobu2009-03-221-29/+49
| | | | | | | application name for batch files. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23031 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_conv_from_wstr): added.nobu2009-03-201-56/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_spawn, rb_w32_aspawn): omit program namenobu2009-03-201-50/+117
| | | | | | | if actual program path is found. [ruby-core:22960] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23023 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (errmap): added ERROR_MOD_NOT_FOUND.nobu2009-03-201-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23017 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (init_env): set TMPDIR if none of TMPDIR, TMP,nobu2009-03-111-55/+0
| | | | | | | TEMP is set. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22886 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_telldir, rb_w32_seekdir): should use long.nobu2009-03-111-8/+113
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22885 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c: suppress warnings. based on a patch from Charlienobu2009-03-101-23/+24
| | | | | | | Savage at [ruby-core:22804]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22879 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_sysinit): initializes version info first.nobu2009-03-051-14/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (Win32System, Win32Version): moved before get_version.nobu2009-03-051-3/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22780 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_osid): always define for binary compatibility.nobu2009-03-051-12/+25
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22779 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (init_env): keeps wide chars as wide chars.nobu2009-03-021-20/+37
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * io.c (sysopen_func, rb_sysopen_internal, rb_sysopen): open fileusa2009-02-251-3/+34
| | | | | | | | | | | | | | | | | | | by UTF-16'ed filename on Windows. * io.c (rb_file_open_generic, rb_io_s_sysopen, rb_io_reopen, argf_next_argv): follow above change. * io.c (rb_scan_open_args): no longer need to convert filepath here on Windows. * win32/wio32.c (rb_w32_wopen): new function to open file by UTF-16'ed filename. * win32/win32.c (rb_w32_open): call rb_w32_open(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22626 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * debug.c (set_debug_option): added rtc_error option.nobu2009-02-161-3/+25
| | | | | | | | | | | | | * win32/Makefile.sub (CRTDEFFLAGS): separated from DEFS. * win32/win32.c (rtc_error_handler): ignores RTC errors unless rtc_error debug option is given. * win32/win32.c (rb_w32_sysinit): suppress useless CRT assertions. [ruby-core:22116] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22337 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (_CrtDbgReportW): prevent from false positivenobu2009-02-151-0/+2
| | | | | | | assertions in msvcrtd. [ruby-core:22116] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_readdir_with_enc): fallback to OS convertionusa2009-02-061-1/+4
| | | | | | | | when ASCII-8BIT is passed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/{dir.h, win32.c} (rb_w32_readdir_with_enc): new function tousa2009-02-061-35/+95
| | | | | | | | | | | | | | | read entry with specified enc. * win32/win32.c (readdir_internal): extract from rb_w32_opendir(). * win32/win32.c (opendir_internal): extract from rb_w32_readdir(). * dir.c (dir_read, dir_each): use new READDIR macro instead of readdir() to pass enc for special version of readdir, such as above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22087 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_write): use of cast expressions as lvaluesnobu2009-02-021-1/+1
| | | | | | | is deprecated. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21986 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (open_dir_handle, rb_w32_opendir, move_to_next_entry,usa2009-02-021-27/+37
| | | | | | | | rb_w32_readdir, check_valid_dir): change backend API from A to W. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_write): limit write size to 32KB if the fileusa2009-01-301-2/+17
| | | | | | | | seems to be console. [ruby-core:21613] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * revert previous revision. it's already out-of-date.usa2009-01-221-9/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21735 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * include/ruby/win32.h, win32/win32.c (rb_w32_is_valid_fd): new functionusa2009-01-221-0/+9
| | | | | | | | | | to validate fd. * io.c (rb_io_initialize): check fd with above function. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21734 b2dd03c8-39d4-4d8f-98ff-823fe69b080e