summaryrefslogtreecommitdiff
path: root/file.c
AgeCommit message (Collapse)Author
2008-06-18 * file.c: fixes to compile on mswin32. Patch from U. Nakamurashyouhei
<usa at garbagecollect.jp>. [ruby-dev:35127] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17397 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-15merge revision(s) 16618:shyouhei
* file.c (BUFCHECK): wrong condition. [ruby-core:16921] * file.c (file_expand_buf): shouldn't use buflen for length of string. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-15merge revision(s) 16420,16454:shyouhei
* file.c (file_expand_path): support for alternative data stream and ignored trailing garbages of NTFS. * file.c (rb_file_s_basename): ditto. * file.c (rb_file_s_extname): ditto. * lib/webrick/httpservlet/filehandler.rb: should normalize path name in path_info to prevent script disclosure vulnerability on DOSISH filesystems. (fix: CVE-2008-1891) Note: NTFS/FAT filesystem should not be published by the platforms other than Windows. Pathname interpretation (including short filename) is less than perfect. * lib/webrick/httpservlet/abstract.rb (WEBrick::HTTPServlet::AbstracServlet#redirect_to_directory_uri): should escape the value of Location: header. * lib/webrick/httpservlet/cgi_runner.rb: accept interpreter command line arguments. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17303 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-15merge revision(s) 15477:shyouhei
* configure.in (ftruncate): check if available. * file.c (rb_file_truncate): check if ftruncate instead of truncate. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-17* file.c (isdirsep): backslash is valid path separator on cygwin too.nobu
backported from 1.8 HEAD. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16451 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-17* file.c (file_expand_path): fix for short file name on Cygwin.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16450 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-17* file.c (OpenFile): prevent conflict on Windows.nobu
* file.c (USE_NTFS): fixed merge miss. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-17* file.c (file_expand_path): rb_str_set_len is not backported.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16443 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-05-17* file.c (file_expand_path): support for alternative data streamnobu
and ignored trailing garbages of NTFS. * file.c (rb_file_s_basename): ditto. * file.c (rb_file_s_extname): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16442 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-07 * configure.in (group_member): check if presents.shyouhei
* configure.in (XCFLAGS): add _GNU_SOURCE on linux. * file.c (group_member): use system routine if available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13393 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-22 * file.c (rb_file_s_rename): deleted code to get rid of a bug ofshyouhei
old Cygwin. * file.c (rb_file_truncate): added prototype of GetLastError() on cygwin. [ruby-dev:31239] * intern.h (is_ruby_native_thread): prototype. * missing/strftime.c (strftime): fix printf format and actual arguments. * ext/Win32API/Win32API.c (Win32API_initialize): ditto. * ext/tk/tcltklib.c (ip_finalize): ditto. * ext/dl/ptr.c (rb_dlptr_inspect): ditto. [ruby-dev:31268] * ext/dl/sym.c (rb_dlsym_inspect): ditto. * ext/socket/getnameinfo.c: include stdio.h always. * ext/win32ole/win32ole.c (ole_hresult2msg, folevariable_name, folevariable_ole_type, folevariable_ole_type_detail, folevariable_value, folemethod_visible): missing return value. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13200 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22merge -c 12127shyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-03-04* file.c (rb_file_s_utime): allow nil to set the current time.knu
* lib/fileutils.rb (touch): ditto, and added :mtime and :nocreate options. fixed: [ruby-talk:219037] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@11987 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-01-09* file.c (rb_find_file): should not call fpath_check() with NULL.usa
fixed: [ruby-core:09867] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11519 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-11-22* file.c (test_grpowned, rb_stat_grpowned): should honormatz
supplementary group IDs. [ruby-core:09546] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11302 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-25* file.c (rb_path_end): skip root directory. fixed: [ruby-core:08913]nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-07* file.c (path_check_0, fpath_check): disable path check on cygwin.nobu
[ruby-talk:213074] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10874 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-04* file.c (path_check_0): check if sticky bit is set on parentnobu
directories for executable path. fixed: [ruby-dev:29415] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-27Fix documentation submitted by Rick Ohnemus. ruby-Bugs-5529. [ruby-core:08725]drbrain
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10785 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-19* file.c (rb_file_s_rename): use errno if set properly.nobu
fixed: [ruby-dev:29293] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10747 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-17* file.c (rb_stat_[rRwWxX]): check for super user.nobu
fixed: [ruby-core:08616] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-07-20* ruby.h: export classes/modules to implement sandbox.matz
[ruby-core:08283] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10573 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-06* file.c (cygwin_flock): save old errno.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9904 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-06* file.c (rb_thread_flock): ERROR_NOT_LOCKED is not an error on Cygwin.eban
In such situation, flock() should return 0. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-25* configure.in, dln.c, file.c, intern.h, missing.h (eaccess): usenobu
system routine if provided. fixed: [ruby-core:07195] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9856 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-13* file.c (rb_file_s_chmod): avoid warning where sizeof(int) !=ocean
sizeof(void*). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9832 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-12-29* file.c (eaccess): workaround for VC++8 runtime.usa
* win32/win32.c (ioinfo): VC++8 support. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9767 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-12-21(rb_f_test): fix document. [ruby-dev:28087]akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9731 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-12-21* file.c (w32_io_info): should return handle because FileIndex isocean
valid only while file is open. [ruby-dev:28088] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9730 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-23* file.c (w32_io_info): CreateFile failed on Win9x if file was alreadyocean
opened. (FILE_SHARE_READ was needed, but actually I don't understand the flags of CreateFile well...) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9604 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-23* file.c (w32_io_info): should not call GetFileInformationByHandleocean
for pipe. * file.c (w32_io_info): checks return value from rb_w32_get_osfhandle. * file.c (w32_io_info): now can identify directory on WinNT. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9600 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-23* intern.h, file.c: failed to compile on windows.ocean
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-22* file.c (test_identical): test if two files are identical.nobu
* file.c (rb_f_test): support DOSISH systems where st_ino is not reliable. fixed: [ruby-core:06672] * win32.h, win32.c (rb_w32_osid): check the running platform. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-22* file.c (rb_file_s_basename): skip slashes just after UNC top slashes.usa
* test/ruby/test_path.rb (test_dirname, test_basename): follow new spec. and add new tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9587 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-21* file.c (rb_file_s_basename): DOSISH_UNC is defined on cygwin butnobu
DOSISH is not. fixed: [ruby-dev:27797] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9580 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-21* file.c (rb_path_skip_prefix, rb_file_s_basename): UNC without pathnobu
should not be splitted. fixed: [ruby-dev:27776] [ruby-dev:27786] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9578 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-18* file.c (rb_file_s_dirname): should use skipprefix for UNC path.usa
pointed out by nobu ([ruby-dev:27744]). fixed: [ruby-core:5076] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9563 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-18* file.c (file_s_dirname): added checks for some patterns with driveusa
letter. fixed: [ruby-dev:27738] * test/ruby/test_path.rb (test_dirname): added tests for above patterns. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9561 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-14* file.c (rb_file_s_readlink): ERANGE will occur only on GPFS.nobu
[ruby-dev:27699] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9537 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-10* configure.in: undef HAVE_LINK on BeOS. (link(2) always returnsocean
EINVAL, and this causes error in test/fileutils.) * file.c: overwride chown(2) and fchown(2) on BeOS. (these functions should not change user/group id if -1 is passed as corresponding argument, and this causes error in test/fileutils too) [ruby-dev:27672] * file.c (rb_file_s_link): checks HAVE_LINK. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-06* file.c (rb_file_s_readlink): readlink(2) on AIX fails with ERANGE ifnobu
buffer size is less than required. fixed: [ruby-dev:27634] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9505 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-10-18* file.c (rb_file_join): elements may contain null pointer strings.nobu
report and fixed by Lloyd Zusman (hippoman): [ruby-core:06326] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9415 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-10-17* file.c (chmod_internal, lchmod_internal): fixed type of 2nd argument.usa
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9403 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-10-12* file.c (rb_f_test): typos in RDoc comments.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9380 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-10-12* file.c (rb_f_test): typo in RDoc comments.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9378 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-28* class.c (rb_mod_init_copy, rb_class_init_copy), file.c (rb_stat_init_copy),nobu
numeric.c (num_init_copy), object.c (rb_obj_init_copy, Init_Object), re.c (match_init_copy, rb_reg_init_copy), time.c (time_init_copy): undocumented. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9332 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-28* file.c (apply2files): add prototype.nobu
* file.c (rb_stat_inspect): constified. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-20* file.c (fpath_check): typo fixed.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-20* file.c (path_check_0): disallow sticky world writable directorymatz
in PATH (and $LOAD_PATH). [ruby-dev:27226] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-19* file.c (rb_file_chown): should accept nil. [ruby-dev:27171] (backport from ↵aamine
trunk, rev 1.208) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9233 b2dd03c8-39d4-4d8f-98ff-823fe69b080e