diff -ubNr dotconf-1.0.6/ChangeLog dotconf-1.0.7/ChangeLog --- dotconf-1.0.6/ChangeLog Tue Aug 28 09:32:02 2001 +++ dotconf-1.0.7/ChangeLog Sat Dec 29 18:35:40 2001 @@ -1,3 +1,13 @@ +[2001 12 29] + - win32 cleanups, by Robert Buck + +[2001 12 05] + - documentation fix for dotconf_create, suggested by Mike Swieton + +[2001 10 18] + - FIXED: Hubert Leineweber of multilink.de found a bug in the inline-comment + handling + [2001 08 28] [v1.0.6] diff -ubNr dotconf-1.0.6/README dotconf-1.0.7/README --- dotconf-1.0.6/README Mon Aug 27 23:29:12 2001 +++ dotconf-1.0.7/README Sat Dec 29 19:02:02 2001 @@ -1,4 +1,4 @@ -dot.conf v1.0.6 http://www.azzit.de/dotconf/ +dot.conf v1.0.7 http://www.azzit.de/dotconf/ ===================================================================== please refer to the API documentation in the doc/ directory of the diff -ubNr dotconf-1.0.6/configure dotconf-1.0.7/configure --- dotconf-1.0.6/configure Tue Aug 28 09:25:11 2001 +++ dotconf-1.0.7/configure Sat Dec 29 18:36:34 2001 @@ -1108,9 +1108,9 @@ # DOTCONF_MAJOR_VERSION=1 DOTCONF_MINOR_VERSION=0 -DOTCONF_MICRO_VERSION=6 -DOTCONF_INTERFACE_AGE=6 -DOTCONF_BINARY_AGE=6 +DOTCONF_MICRO_VERSION=7 +DOTCONF_INTERFACE_AGE=7 +DOTCONF_BINARY_AGE=7 DOTCONF_VERSION=$DOTCONF_MAJOR_VERSION.$DOTCONF_MINOR_VERSION.$DOTCONF_MICRO_VERSION # libtool versioning @@ -1305,7 +1305,7 @@ PACKAGE=dotconf -VERSION=1.0.6 +VERSION=1.0.7 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then { { echo "$as_me:1311: error: source directory already configured; run \"make distclean\" there first" >&5 diff -ubNr dotconf-1.0.6/configure.in dotconf-1.0.7/configure.in --- dotconf-1.0.6/configure.in Tue Aug 28 09:25:04 2001 +++ dotconf-1.0.7/configure.in Wed Dec 5 11:53:51 2001 @@ -10,9 +10,9 @@ # DOTCONF_MAJOR_VERSION=1 DOTCONF_MINOR_VERSION=0 -DOTCONF_MICRO_VERSION=6 -DOTCONF_INTERFACE_AGE=6 -DOTCONF_BINARY_AGE=6 +DOTCONF_MICRO_VERSION=7 +DOTCONF_INTERFACE_AGE=7 +DOTCONF_BINARY_AGE=7 DOTCONF_VERSION=$DOTCONF_MAJOR_VERSION.$DOTCONF_MINOR_VERSION.$DOTCONF_MICRO_VERSION AC_SUBST(DOTCONF_MAJOR_VERSION) @@ -32,7 +32,7 @@ AC_SUBST(LT_REVISION) AC_SUBST(LT_AGE) -AM_INIT_AUTOMAKE(dotconf, 1.0.6) +AM_INIT_AUTOMAKE(dotconf, 1.0.7) AM_CONFIG_HEADER(config.h) AC_CANONICAL_HOST diff -ubNr dotconf-1.0.6/doc/dotconf-api.txt dotconf-1.0.7/doc/dotconf-api.txt --- dotconf-1.0.6/doc/dotconf-api.txt Sat Jun 30 12:59:15 2001 +++ dotconf-1.0.7/doc/dotconf-api.txt Wed Dec 5 11:45:48 2001 @@ -272,7 +272,7 @@ return value: configfile_t * the dot.conf session structure, which is to be used in every - call to another dot.conf API function. + call to another dot.conf API function. NULL is returned in case of a failure sideeffects: the returned configfile_t* is malloc()ed, and the field 'stream' is diff -ubNr dotconf-1.0.6/examples/caseinsensitive/caseinsensitive.conf dotconf-1.0.7/examples/caseinsensitive/caseinsensitive.conf --- dotconf-1.0.6/examples/caseinsensitive/caseinsensitive.conf Tue Aug 28 09:32:10 2001 +++ dotconf-1.0.7/examples/caseinsensitive/caseinsensitive.conf Sat Dec 29 19:02:08 2001 @@ -1,4 +1,5 @@ StrNCAseCMp 'as registered' sTRncaSecMP 'mixed case' strncasecmp 'lower case' -STRNCASECMP 'upper case' +STRNCASECMP 'upper case' # inline comment + diff -ubNr dotconf-1.0.6/mkinstalldirs dotconf-1.0.7/mkinstalldirs --- dotconf-1.0.6/mkinstalldirs Thu Jul 26 11:28:25 2001 +++ dotconf-1.0.7/mkinstalldirs Thu Oct 18 17:30:21 2001 @@ -4,7 +4,7 @@ # Created: 1993-05-16 # Public domain -# $Id: mkinstalldirs,v 1.13 1999/01/05 03:18:55 bje Exp $ +# $Id: mkinstalldirs,v 1.2 2001/10/18 15:30:21 lukas Exp $ errstatus=0 diff -ubNr dotconf-1.0.6/src/dotconf.c dotconf-1.0.7/src/dotconf.c --- dotconf-1.0.6/src/dotconf.c Mon Aug 27 22:44:37 2001 +++ dotconf-1.0.7/src/dotconf.c Sat Dec 29 18:43:46 2001 @@ -46,20 +46,20 @@ #include #include #include + #ifndef WIN32 + #include #include + #else /* ndef WIN32 */ + #include "readdir.h" /* WIN32 fix by Robert J. Buck */ + #define strncasecmp strnicmp typedef unsigned long ulong; #define snprintf _snprintf #define vsnprintf _vsnprintf -#define R_OK 0 -int access(const char *pathname, int mode) -{ - return 0; -} #endif /* !WIN32 */ #include @@ -429,6 +429,7 @@ else if (*cp1 == '#' && !dq && !sq) { *cp2 = '\0'; + break; } /* not space or quoted:eat it; dont take quote if quoting */ else if ( (!isspace((int)*cp1) && !dq && !sq && *cp1 != '"' && *cp1 != '\'') @@ -552,7 +553,7 @@ command.data.list[command.arg_count++] = strdup(cp1); /* has an option entry been found before or do we have to use a fallback? */ - else if ((option->name && option->name[0] > 32) || option->type == ARG_NAME) + if ((option->name && option->name[0] > 32) || option->type == ARG_NAME) { /* found it, now check the type of args it wants */ switch (option->type) diff -ubNr dotconf-1.0.6/src/dotconf.h dotconf-1.0.7/src/dotconf.h --- dotconf-1.0.6/src/dotconf.h Tue Jul 3 11:52:16 2001 +++ dotconf-1.0.7/src/dotconf.h Sat Dec 29 18:43:29 2001 @@ -10,6 +10,12 @@ #include /* needed for FILE* */ #endif +#ifdef WIN32 +# ifndef R_OK +#define R_OK 0 +# endif +#endif + /* some buffersize definitions */ #define CFG_BUFSIZE 4096 /* max length of one line */ #define CFG_MAX_OPTION 32 /* max length of any option name */ diff -ubNr dotconf-1.0.6/src/readdir.c dotconf-1.0.7/src/readdir.c --- dotconf-1.0.6/src/readdir.c Mon Aug 27 23:13:38 2001 +++ dotconf-1.0.7/src/readdir.c Sat Dec 29 18:30:28 2001 @@ -77,7 +77,7 @@ * The DIR typedef is not compatible with Unix. **********************************************************************/ -API_EXPORT(DIR *) opendir(const char *dir) +DIR * opendir(const char *dir) { DIR *dp; char *filespec; @@ -109,7 +109,7 @@ return dp; } -API_EXPORT(struct dirent *) readdir(DIR *dp) +struct dirent * readdir(DIR *dp) { if (!dp || dp->finished) return NULL; @@ -129,7 +129,7 @@ return &(dp->dent); } -API_EXPORT(int) closedir(DIR *dp) +int closedir(DIR *dp) { if (!dp) return 0; _findclose(dp->handle); diff -ubNr dotconf-1.0.6/src/readdir.h dotconf-1.0.7/src/readdir.h --- dotconf-1.0.6/src/readdir.h Tue Aug 14 10:03:02 2001 +++ dotconf-1.0.7/src/readdir.h Sat Dec 29 18:31:17 2001 @@ -71,10 +71,6 @@ #include #include -#ifndef API_EXPORT -# define API_EXPORT(type) __declspec(dllexport) type __stdcall -#endif - /* struct dirent - same as Unix */ struct dirent { long d_ino; /* inode (always 1 in WIN32) */ @@ -94,9 +90,9 @@ } DIR; /* Function prototypes */ -API_EXPORT(DIR *) opendir(const char *); -API_EXPORT(struct dirent *) readdir(DIR *); -API_EXPORT(int) closedir(DIR *); +DIR * opendir(const char *); +struct dirent * readdir(DIR *); +int closedir(DIR *); #endif /* WIN32 */