httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karl Fogel <kfo...@galois.collab.net>
Subject APR build fails, typo in fileacc.c (patch included)
Date Thu, 02 Nov 2000 14:45:39 GMT
There was a typo in fileacc.c: when configured for most (all?) Unixes,
`apr_file_t' does not have a field named `n', it just has `fname'.

The fix below is minimal.  I don't quite understand the relationships
between

   file_io/unix/fileacc.c
   file_io/win32/fileacc.c
   file_io/unix/fileio.h
   file_io/win32/fileio.h

In win32/fileio.h, apr_file_t has a field `n', but in unix/fileio.h,
it does not.  Someone who understands the mixing of Win32 and Unix
code might be able to make a better fix.

I think the APR nightly autobuilds will help a lot.  I'm sure APR also
has a policy of committers checking that their changes compile before
they check in, the problem in this case (I imagine) was that the
changes compiled fine under Windows, just not under Unix.


2000-11-02  Karl Fogel  <kfogel@collab.net>

	* file_io/unix/fileacc.c (apr_get_filename): access correct
	structure field when neither WIN32 nor APR_HAS_UNICODE_FS.


--- file_io/unix/fileacc.c.orig	Thu Nov  2 08:35:03 2000
+++ file_io/unix/fileacc.c	Thu Nov  2 08:35:07 2000
@@ -92,7 +92,7 @@
     }
     else
 #endif
-        *fname = apr_pstrdup(thefile->cntxt, thefile->n.fname);
+        *fname = apr_pstrdup(thefile->cntxt, thefile->fname);
     return APR_SUCCESS;
 }
 

Mime
View raw message