summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--win32/win32.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 20bc9beeb6..8debe45ab2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Fri Aug 1 14:54:42 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * win32/win32.c (rb_w32_seekdir): no need to rewind to seek forward.
+
Fri Aug 1 05:31:08 2008 NARUSE, Yui <naruse@ruby-lang.org>
* transcode.c (output_replacement_character):
diff --git a/win32/win32.c b/win32/win32.c
index 9285b44a42..04a11f3fb8 100644
--- a/win32/win32.c
+++ b/win32/win32.c
@@ -1628,7 +1628,7 @@ rb_w32_telldir(DIR *dirp)
void
rb_w32_seekdir(DIR *dirp, off_t loc)
{
- rb_w32_rewinddir(dirp);
+ if (dirp->loc > loc) rb_w32_rewinddir(dirp);
while (dirp->curr && dirp->loc < loc) {
move_to_next_entry(dirp);