[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

APR build fails, typo in fileacc.c (patch included)

From: Karl Fogel <kfogel_at_galois.collab.net>
Date: 2000-11-02 15:45:39 CET

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;
 }
Received on Sat Oct 21 14:36:14 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.