Project

General

Profile

Actions

Bug #382

closed

Dir#tell leads to segfaults in Dir#read on win32

Added by Anonymous about 13 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
ruby -v:
[ruby-core:18041]

Description

=begin
rb_w32_telldir calculates the position on each call by repeatedly calling move_to_next_entry.
This increases dirp->loc each time and leads to segfaults in rb_w32_readdir when reading dirp->bits because dirp->loc can be larger than allowed. Simply returning dirp->loc in rb_w32_telldir and zeroing it in rb_w32_rewinddir should suffice.

This bug seemed to never got introduced into the 1.9 branch.
=end


Files

ruby-1.8.7-win32-telldir.patch (535 Bytes) ruby-1.8.7-win32-telldir.patch Anonymous, 08/01/2008 11:56 AM
Actions

Also available in: Atom PDF