stoddard 2004/07/19 08:39:54
Modified: . CHANGES
file_io/win32 seek.c
Log:
Win32: Fix bug in tracking the file pointer in files opened for
overlapped/xthread io
Revision Changes Path
1.482 +3 -0 apr/CHANGES
Index: CHANGES
===================================================================
RCS file: /home/cvs/apr/CHANGES,v
retrieving revision 1.481
retrieving revision 1.482
diff -u -r1.481 -r1.482
--- CHANGES 8 Jul 2004 23:18:52 -0000 1.481
+++ CHANGES 19 Jul 2004 15:39:53 -0000 1.482
@@ -5,6 +5,9 @@
and upgrading it to do SHA-256. Not yet ready for prime time.
[Ben Laurie]
+ *) Win32: Fix bug tracking the file pointer on a file opened for
+ overlapped/APR_XTHREAD io. [Bill Stoddard]
+
Changes with APR 1.0
*) Add jlibtool - enabled with '--enable-experimental-libtool' option.
1.30 +5 -2 apr/file_io/win32/seek.c
Index: seek.c
===================================================================
RCS file: /home/cvs/apr/file_io/win32/seek.c,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -r1.29 -r1.30
--- seek.c 4 May 2004 00:07:32 -0000 1.29
+++ seek.c 19 Jul 2004 15:39:54 -0000 1.30
@@ -82,8 +82,11 @@
*offset = thefile->filePtr - thefile->dataRead + thefile->bufpos;
return rc;
- }
- else if (thefile->pOverlapped) {
+ }
+ /* A file opened with APR_XTHREAD has been opened for overlapped i/o.
+ * APR must explicitly track the file pointer in this case.
+ */
+ else if (thefile->pOverlapped || thefile->flags & APR_XTHREAD) {
switch(where) {
case APR_SET:
thefile->filePtr = *offset;