summaryrefslogtreecommitdiff
path: root/win32/win32.c
AgeCommit message (Collapse)Author
2014-08-23* win32/win32.c (cmdglob): use inline function.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-21win32.c: manage reverse videonobu
* win32/win32.c (constat_attr): manage reverse video internally since Windows console window does not manage it. based on the patch by white leaf in [ruby-dev:48483]. [Bug #10158] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47241 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-09win32/file.c: share functions with win32.cnobu
* win32/file.c (rb_file_expand_path_internal, rb_file_load_ok): use functions defined in win32/win32.c. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47117 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23win32.c: unused variablenobu
* win32/win32.c (envarea): remove no longer used variable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46533 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-02* win32/win32.c (rb_w32_conv_from_wchar): follow nobu's previous commit.usa
hey nobu, why don't you write Changelog for such serious changes? git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46324 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-05-22revert File::Statfs [Feature #9772]naruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-05-18win32.c: fix infinite recursionnobu
* win32/win32.c: include "missing/nextafter.c" and address finite() and isnan() macros, to get rid of infinite recursion. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-30win32.c: add linkagenobu
* win32/win32.c (ustatfs): need a linkage to get rid of conflict. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45770 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-30win32.c: declare for old VCnobu
* win32/win32.c (ustatfs): declare GetVolumePathNameW for old VC. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-22* win32/win32.c, include/ruby/win32.h (ustatfs): implementation ofusa
statfs(2) clone. [EXPERIMENTAL] * file.c (rb_io_statfs): use above function. * configure.in, win32/Makefile.sub (struct statfs): available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45672 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-16win32.c: CharNextExA with cpnobu
* win32/win32.c (dln_find_1): use CharNextExA() instead of CharNext() to respect the given code page. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45597 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-15win32.c: adjust typenobu
* win32/win32.c (NtCmdLineElement): use long instead of int for rb_w32_wstr_to_mbstr. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-15* include/ruby/win32.h (rb_w32_cmdvector): removed.usa
* win32/win32.c (rb_w32_sysinit): use WCHAR version of GetCommandLine() internally. * win32/win32.c (w32_cmdvector): renamed from rb_w32_cmdvector. use WCHAR* instead of char* internally. these changes are expected to not changing the behavior yet. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45592 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-04-05win32.c: wchar conversionnobu
* win32/win32.c (rb_w32_wstr_to_mbstr, rb_w32_mbstr_to_wstr): make WCHAR/mb conversion functions public. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45521 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-03-30* win32/win32.c (rb_w32_accept, open_ifs_socket, socketpair_internal):usa
reset inherit flag of socket to avoid unintentional inheritance of socket. note that the return value of SetHandleInformation() is not verified intentionally because old Windows may return an error. [Bug #9688] [ruby-core:61754] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45471 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-02-23win32/win32.c: add rb_w32_inet_ptonnobu
* include/ruby/win32.h, win32/win32.c (rb_w32_inet_pton): add a wrapper function for inet_pton minimum supported client is Vista, as well as inet_ntop. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-25win32/win32.c: mingw junglenobu
* configure.in: let mingw do something black-magic, and check if _gmtime64_s() is available actually. * win32/win32.c (gmtime_s, localtime_s): use _gmtime64_s() and _localtime64_s() if available, not depending on very confusing mingw variants macros. based on the patch by phasis68 (Heesob Park) at [ruby-core:58764]. [ruby-core:58391] [Bug #9119] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44406 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-11-28win32.c: rb_w32_dup2nobu
* win32/win32.c (rb_w32_dup2): extract from rb_cloexec_dup2() and redirect_dup2(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43890 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-17win32.c: check by module handlesnobu
* win32/win32.c (console_emulator_p): check by comparison between module handle of WriteConsoleW and kernel32.dll. * configure.in, win32/Makefile.sub, win32/setup.mak: no longer need psapi.lib. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-16win32/setup.mak: check psapi.hnobu
* win32/setup.mak (check-psapi.h): check if psapi.h is available. * win32/win32.c (CHECK_CONSOLE_EMULATOR): enable console emulator DLL check only when psapi.h is available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-10win32.c: bail out if no memorynobu
* win32/win32.c (rb_w32_write_console): bail out when buffer allocation failed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-07win32.c: internal functionsnobu
* win32/win32.c (w32_spawn, w32_aspawn_flags): make internal functions static. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43161 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-10-03win32.c: disable console colorizingnobu
* win32/win32.c (console_emulator_p, constat_handle): disable built-in console colorizing when console-emulator-like DLL is injected. [Feature #8201] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43131 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-06win32.c: clock_getresnobu
* win32/win32.c (clock_getres): remove unused variable. [ruby-dev:47699] [Bug #8869] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42856 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-06win32.c: clock_getresnobu
* win32/win32.c (clock_getres): required as well as clock_gettime(). [ruby-dev:47699] [Bug #8869] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42855 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-04win32.c: suppress warningnobu
* win32/win32.c (do_select): unconstify timeout as select() declares it non-const. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42831 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-03* win32/win32.c (rb_w32_select_with_thread): rounding up the fraction ofusa
tv_usec instead of rounding down. this change is an experiment to get rid of failures on vc10-x64 CI. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42793 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-03* win32/win32.c (do_select): constify timeout.usa
* win32/win32.c (rb_w32_select_with_thread): constify 10ms wait and 0ms wait structs. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42792 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-19* include/ruby/win32.h (CLOCK_MONOTONIC): typo.usa
* win32/win32.c: removed duplicated declarations. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42617 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-15* win32/win32.c (clock_gettime): improve precision when freq is lessusa
than and nearly equals 10**9. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-15* include/ruby/win32.h, win32/Makefile.sub, win32/win32.cusa
(clock_gettime): [experimental] emulates clock_gettime(2) of posix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-06win32.c: fix conversionnobu
* win32/win32.c (rb_w32_conv_from_wchar): converted string to CP_UTF8 should have UTF-8 encoding. otherwise no conversion takes place later. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42399 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-06win32.c: conversion from WCHARnobu
* win32/win32.c (rb_w32_conv_from_wchar): use WideCharToMultiByte(), as like as mbstr_to_wstr(), in the first step of the convertion from WCHAR. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42397 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-06win32.c: supprss warningnobu
* win32/win32.c (rb_w32_system_tmpdir): supprss a sign-compare warning. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42394 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-05win32.c: conversion to WCHARnobu
* win32/win32.c (rb_w32_write_console): use MultiByteToWideChar() for the last step of conversion to WCHAR, to get rid of warnings from rb_enc_find() in miniruby. [ruby-dev:47584] [Bug #8733] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42385 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-05win32.c: fix wrong trimmingnobu
* win32/win32.c (wstr_to_mbstr, mbstr_to_wstr): fix wrong trimming. WideCharToMultiByte() and MultiByteToWideChar() do not count NUL-terminator in the size for conversion result, unless the input length is -1. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42384 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-28win32.c: use enumnobu
* win32/win32.c (rb_w32_pipe): use enum for compile time constants, instead of const int for debugging. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-28win32.c: fix pipe name formattingnobu
* win32/win32.c (rb_w32_pipe): fix pipe name formatting. as "%x" may not contain '0' at all, fill at fixed position instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42207 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-11win32.c: fix infinite recursionnobu
* win32/win32.c (rb_w32_pow): undef pow to get rid of infinite recursive call. re-fix [Bug #8495]. [ruby-core:55923] [Bug #8621] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41923 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-08win32.c: suppress warningsnobu
* win32/win32.c (CharNextExA): cast to suppress warnings by VC6. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41837 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-08win32.c: for strict ANSInobu
* win32/win32.c (rb_w32_pow): move from win32.h and disable strict ANSI mode macro to let _controlfp() stuff defined. [ruby-core:55312] [Bug #8495] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41836 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-08win32: for strict ANSInobu
* thread_win32.c (w32_thread_start_func, thread_start_func_1), (timer_thread_func): use __stdcall instead of _stdcall which is unavailable in strict ANSI mode. [ruby-core:55312] [Bug #8495] * win32/win32.c (gettimeofday): use __cdecl instead of _cdecl. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-05* win32/win32.c (w32_spawn): r41710 made that if the command starts withusa
a quote and includes slash, removed the top quote and NOT removed the last quote. this fixes test failures on test/ruby/test_process.rb and test/webrick. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: use backslashnobu
* win32/win32.c (join_argv): use backslash instead of slash in program path, otherwise cannot invoke "./c\u{1ee7}a.exe" for some reason. [ruby-core:24309] [Bug #1771] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41710 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: codepage awarenessnobu
* win32/win32.c (translate_char, join_argv, has_redirection): make codepage aware. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41708 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: rb_w32_udln_find_exe_r,nobu
rb_w32_udln_find_file_r * win32/win32.c (rb_w32_udln_find_exe_r, rb_w32_udln_find_file_r): codepage independent versions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41707 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: UTF-8 spawnnobu
* win32/win32.c (w32_spawn): extract codepage aware code from rb_w32_spawn(). * win32/win32.c (rb_w32_uspawn): add UTF-8 version function. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41706 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: UTF-8 aspawnnobu
* win32/win32.c (w32_aspawn_flags): extract codepage aware code from rb_w32_aspawn_flags(). * win32/win32.c (rb_w32_uaspawn_flags, rb_w32_uaspawn_flags): add UTF-8 version functions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41705 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: w32_getenvnobu
* win32/win32.c (w32_getenv): extract codepage aware code from rb_w32_ugetenv() and rb_w32_getenv(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-30win32.c: w32_stati64nobu
* win32/win32.c (w32_stati64): extract codepage aware code from rb_w32_ustati64() and rb_w32_stati64(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41703 b2dd03c8-39d4-4d8f-98ff-823fe69b080e