Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package dotconf for openSUSE:Factory checked 
in at 2024-04-24 15:13:30
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/dotconf (Old)
 and      /work/SRC/openSUSE:Factory/.dotconf.new.1880 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "dotconf"

Wed Apr 24 15:13:30 2024 rev:23 rq:1169820 version:1.4.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/dotconf/dotconf.changes  2021-08-16 
10:13:41.474948274 +0200
+++ /work/SRC/openSUSE:Factory/.dotconf.new.1880/dotconf.changes        
2024-04-24 15:13:51.524054208 +0200
@@ -1,0 +2,14 @@
+Sun Apr 21 13:41:43 UTC 2024 - Andrea Manzini <andrea.manz...@suse.com>
+
+- removed empty useless %check section
+
+-------------------------------------------------------------------
+Tue Apr 16 08:27:39 UTC 2024 - Andrea Manzini <andrea.manz...@suse.com>
+
+- Update to version 1.4.1
+  * fix possible buffer overflows in get_path and dotconf_get_next_line
+
+- fixed package group
+- added empty %check section (no unit tests in the project)
+
+-------------------------------------------------------------------

Old:
----
  v1.3.tar.gz

New:
----
  v1.4.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ dotconf.spec ++++++
--- /var/tmp/diff_new_pack.VLovsO/_old  2024-04-24 15:13:52.136076064 +0200
+++ /var/tmp/diff_new_pack.VLovsO/_new  2024-04-24 15:13:52.136076064 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package dotconf
 #
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2024 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           dotconf
-Version:        1.3
+Version:        1.4.1
 Release:        0
 Summary:        Configuration file parser library
 License:        LGPL-2.1-or-later
@@ -28,8 +28,7 @@
 BuildRequires:  automake
 BuildRequires:  gcc-c++
 BuildRequires:  libtool
-BuildRequires:  pkg-config
-BuildRoot:      %{_tmppath}/%{name}-%{version}-build
+BuildRequires:  pkgconfig
 
 %description
 dotconf is a configuration-file parser
@@ -44,7 +43,7 @@
 
 %package -n libdotconf0
 Summary:        Configuration file parser library
-Group:          System/Languages
+Group:          Development/Libraries/C and C++
 # Package was formerly libdotconf-1_0-0
 Provides:       libdotconf-1_0-0 = %{version}
 Obsoletes:      libdotconf-1_0-0 < %{version}
@@ -93,7 +92,6 @@
 rm doc/Makefile*
 
 %post -n libdotconf0 -p /sbin/ldconfig
-
 %postun -n libdotconf0 -p /sbin/ldconfig
 
 %files -n libdotconf0

++++++ v1.3.tar.gz -> v1.4.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/dotconf-1.3/README new/dotconf-1.4.1/README
--- old/dotconf-1.3/README      2010-06-22 05:06:19.000000000 +0200
+++ new/dotconf-1.4.1/README    2024-04-09 17:43:51.000000000 +0200
@@ -1,4 +1,4 @@
-dot.conf v1.3
+dot.conf v1.4.1
 
 This file lists changes that break backward compatibility with previous
 versions.  Please see the files in the doc directory of the distribution for
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/dotconf-1.3/configure.ac 
new/dotconf-1.4.1/configure.ac
--- old/dotconf-1.3/configure.ac        2010-06-22 05:06:19.000000000 +0200
+++ new/dotconf-1.4.1/configure.ac      2024-04-09 17:43:51.000000000 +0200
@@ -2,7 +2,7 @@
 # Process this file with autoconf to produce a configure script.
 
 AC_PREREQ([2.63])
-AC_INIT([dotconf], [1.3], [w.d.hu...@gmail.com])
+AC_INIT([dotconf], [1.4.1], [w.d.hu...@gmail.com])
 AM_INIT_AUTOMAKE([foreign])
 LT_PREREQ([2.2])
 LT_INIT([dlopen])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/dotconf-1.3/src/dotconf.c 
new/dotconf-1.4.1/src/dotconf.c
--- old/dotconf-1.3/src/dotconf.c       2010-06-22 05:06:19.000000000 +0200
+++ new/dotconf-1.4.1/src/dotconf.c     2024-04-09 17:43:51.000000000 +0200
@@ -260,34 +260,48 @@
 {
        /* ------ match [^\\]\\[\r]\n ------------------------------ */
        char *cp1 = buffer + length - 1;
+       int backtrack = 0;
 
-       if (length < 2)
+       if (length == 0)                        /* empty line */
                return 0;
 
-       if (*cp1-- != '\n')
+       if (*cp1-- != '\n')                     /* terminates, no newline */
                return 0;
 
-       if (*cp1 == '\r')
+       backtrack++;
+
+       if (cp1 < buffer)                       /* just newline */
+               return 0;
+
+       if (*cp1 == '\r') {
                cp1--;
+               backtrack++;
+       }
+
+       if (cp1 < buffer)                       /* just carriage return + 
newline */
+               return 0;
 
        if (*cp1-- != '\\')
                return 0;
 
-       cp1[1] = 0;             /* strip escape character and/or newline */
-       return (*cp1 != '\\');
+       backtrack++;
+
+       if (cp1 < buffer || *cp1 != '\\')       /* maybe empty line with just 
escape */
+               return backtrack;
+
+       return 0;
 }
 
 int dotconf_get_next_line(char *buffer, size_t bufsize,
                          configfile_t * configfile)
 {
-       char *cp1, *cp2;
-       char buf2[CFG_BUFSIZE];
-       int length;
+       char *cp1;
+       int length, backtrack;
 
        if (configfile->eof)
                return 1;
 
-       cp1 = fgets(buffer, CFG_BUFSIZE, configfile->stream);
+       cp1 = fgets(buffer, bufsize, configfile->stream);
 
        if (!cp1) {
                configfile->eof = 1;
@@ -296,9 +310,10 @@
 
        configfile->line++;
        length = strlen(cp1);
-       while (dotconf_continue_line(cp1, length)) {
-               cp2 = fgets(buf2, CFG_BUFSIZE, configfile->stream);
-               if (!cp2) {
+       while (length < (bufsize - 1) && (backtrack = 
dotconf_continue_line(buffer, length))) {
+               length -= backtrack;
+               cp1 = fgets(buffer + length, bufsize - length, 
configfile->stream);
+               if (!cp1) {
                        fprintf(stderr,
                                "[dotconf] Parse error. Unexpected end of file 
at "
                                "line %ld in file %s\n", configfile->line,
@@ -307,8 +322,7 @@
                        return 1;
                }
                configfile->line++;
-               strcpy(cp1 + length - 2, cp2);
-               length = strlen(cp1);
+               length += strlen(cp1);
        }
 
        return 0;
@@ -1440,7 +1454,7 @@
        } else {
                len = tmp - name + 1;
                if (len > CFG_MAX_FILENAME)
-                       len -= 1;
+                       len = CFG_MAX_FILENAME;
        }
                snprintf(buf, len, "%s", name);
        return buf;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/dotconf-1.3/src/readdir.c 
new/dotconf-1.4.1/src/readdir.c
--- old/dotconf-1.3/src/readdir.c       2010-06-22 05:06:19.000000000 +0200
+++ new/dotconf-1.4.1/src/readdir.c     2024-04-09 17:43:51.000000000 +0200
@@ -1,138 +1,138 @@
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2000 The Apache Software Foundation.  All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in
- *    the documentation and/or other materials provided with the
- *    distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- *    if any, must include the following acknowledgment:
- *       "This product includes software developed by the
- *        Apache Software Foundation (http://www.apache.org/)."
- *    Alternately, this acknowledgment may appear in the software itself,
- *    if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" must
- *    not be used to endorse or promote products derived from this
- *    software without prior written permission. For written
- *    permission, please contact apa...@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- *    nor may "Apache" appear in their name, without prior written
- *    permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation.  For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- *
- * Portions of this software are based upon public domain software
- * originally written at the National Center for Supercomputing Applications,
- * University of Illinois, Urbana-Champaign.
- */  
-    
-#ifdef WIN32
-    
-#include <malloc.h>
-#include <string.h>
-#include <errno.h>
-    
-#include "readdir.h"
-    
-/**********************************************************************
- * Implement dirent-style opendir/readdir/closedir on Window 95/NT
- *
- * Functions defined are opendir(), readdir() and closedir() with the
- * same prototypes as the normal dirent.h implementation.
- *
- * Does not implement telldir(), seekdir(), rewinddir() or scandir(). 
- * The dirent struct is compatible with Unix, except that d_ino is 
- * always 1 and d_off is made up as we go along.
- *
- * The DIR typedef is not compatible with Unix.
- **********************************************************************/ 
-     DIR * opendir(const char *dir)
+/* ====================================================================
+ * The Apache Software License, Version 1.1
+ *
+ * Copyright (c) 2000 The Apache Software Foundation.  All rights
+ * reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in
+ *    the documentation and/or other materials provided with the
+ *    distribution.
+ *
+ * 3. The end-user documentation included with the redistribution,
+ *    if any, must include the following acknowledgment:
+ *       "This product includes software developed by the
+ *        Apache Software Foundation (http://www.apache.org/)."
+ *    Alternately, this acknowledgment may appear in the software itself,
+ *    if and wherever such third-party acknowledgments normally appear.
+ *
+ * 4. The names "Apache" and "Apache Software Foundation" must
+ *    not be used to endorse or promote products derived from this
+ *    software without prior written permission. For written
+ *    permission, please contact apa...@apache.org.
+ *
+ * 5. Products derived from this software may not be called "Apache",
+ *    nor may "Apache" appear in their name, without prior written
+ *    permission of the Apache Software Foundation.
+ *
+ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
+ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
+ * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+ * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ * ====================================================================
+ *
+ * This software consists of voluntary contributions made by many
+ * individuals on behalf of the Apache Software Foundation.  For more
+ * information on the Apache Software Foundation, please see
+ * <http://www.apache.org/>.
+ *
+ * Portions of this software are based upon public domain software
+ * originally written at the National Center for Supercomputing Applications,
+ * University of Illinois, Urbana-Champaign.
+ */  
+    
+#ifdef WIN32
+    
+#include <malloc.h>
+#include <string.h>
+#include <errno.h>
+    
+#include "readdir.h"
+    
+/**********************************************************************
+ * Implement dirent-style opendir/readdir/closedir on Window 95/NT
+ *
+ * Functions defined are opendir(), readdir() and closedir() with the
+ * same prototypes as the normal dirent.h implementation.
+ *
+ * Does not implement telldir(), seekdir(), rewinddir() or scandir(). 
+ * The dirent struct is compatible with Unix, except that d_ino is 
+ * always 1 and d_off is made up as we go along.
+ *
+ * The DIR typedef is not compatible with Unix.
+ **********************************************************************/ 
+    DIR * opendir(const char *dir)
 {
-        DIR * dp;
-        char *filespec;
-        long handle;
-        int index;
-         filespec = malloc(strlen(dir) + 2 + 1);
-        strcpy(filespec, dir);
-        index = strlen(filespec) - 1;
-        if (index >= 0 && (filespec[index] == '/' || filespec[index] == '\\'))
-                filespec[index] = '\0';
-        strcat(filespec, "/*");
-         dp = (DIR *) malloc(sizeof(DIR));
-        dp->offset = 0;
-        dp->finished = 0;
-        dp->dir = strdup(dir);
-         if ((handle = _findfirst(filespec, &(dp->fileinfo))) < 0) {
-                if (errno == ENOENT)
-                        dp->finished = 1;
-               
+       DIR * dp;
+       char *filespec;
+       long handle;
+       int index;
+       filespec = malloc(strlen(dir) + 2 + 1);
+       strcpy(filespec, dir);
+       index = strlen(filespec) - 1;
+       if (index >= 0 && (filespec[index] == '/' || filespec[index] == '\\'))
+               filespec[index] = '\0';
+       strcat(filespec, "/*");
+       dp = (DIR *) malloc(sizeof(DIR));
+       dp->offset = 0;
+       dp->finished = 0;
+       dp->dir = strdup(dir);
+       if ((handle = _findfirst(filespec, &(dp->fileinfo))) < 0) {
+               if (errno == ENOENT)
+                       dp->finished = 1;
+               
                else
-                        return NULL;
-        }
-         dp->handle = handle;
-        free(filespec);
-         return dp;
- }
+                       return NULL;
+       }
+       dp->handle = handle;
+       free(filespec);
+       return dp;
+}
 
-  struct dirent *readdir(DIR * dp) 
+struct dirent *readdir(DIR * dp) 
 {
-        if (!dp || dp->finished)
+       if (!dp || dp->finished)
                return NULL;
-         if (dp->offset != 0) {
-                if (_findnext(dp->handle, &(dp->fileinfo)) < 0) {
-                        dp->finished = 1;
-                        return NULL;
-                }
-        }
-        dp->offset++;
-         strncpy(dp->dent.d_name, dp->fileinfo.name, _MAX_FNAME);
-        dp->dent.d_ino = 1;
-        dp->dent.d_reclen = (unsigned short)strlen(dp->dent.d_name);
-        dp->dent.d_off = dp->offset;
-         return &(dp->dent);
- }
+       if (dp->offset != 0) {
+               if (_findnext(dp->handle, &(dp->fileinfo)) < 0) {
+                       dp->finished = 1;
+                       return NULL;
+               }
+       }
+       dp->offset++;
+       strncpy(dp->dent.d_name, dp->fileinfo.name, _MAX_FNAME);
+       dp->dent.d_ino = 1;
+       dp->dent.d_reclen = (unsigned short)strlen(dp->dent.d_name);
+       dp->dent.d_off = dp->offset;
+       return &(dp->dent);
+}
 
-  int closedir(DIR * dp) 
+int closedir(DIR * dp) 
 {
-        if (!dp)
+       if (!dp)
                return 0;
-        _findclose(dp->handle);
-        if (dp->dir)
+       _findclose(dp->handle);
+       if (dp->dir)
                free(dp->dir);
-        if (dp)
+       if (dp)
                free(dp);
-         return 0;
- }
+       return 0;
+}
 
-
-#endif /* WIN32 */
+
+#endif /* WIN32 */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/dotconf-1.3/src/readdir.h 
new/dotconf-1.4.1/src/readdir.h
--- old/dotconf-1.3/src/readdir.h       2010-06-22 05:06:19.000000000 +0200
+++ new/dotconf-1.4.1/src/readdir.h     2024-04-09 17:43:51.000000000 +0200
@@ -1,99 +1,99 @@
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2000 The Apache Software Foundation.  All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in
- *    the documentation and/or other materials provided with the
- *    distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- *    if any, must include the following acknowledgment:
- *       "This product includes software developed by the
- *        Apache Software Foundation (http://www.apache.org/)."
- *    Alternately, this acknowledgment may appear in the software itself,
- *    if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" must
- *    not be used to endorse or promote products derived from this
- *    software without prior written permission. For written
- *    permission, please contact apa...@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- *    nor may "Apache" appear in their name, without prior written
- *    permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation.  For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- *
- * Portions of this software are based upon public domain software
- * originally written at the National Center for Supercomputing Applications,
- * University of Illinois, Urbana-Champaign.
- */  
-    
-/*
- * Structures and types used to implement opendir/readdir/closedir
- * on Windows 95/NT.
- */ 
-    
-#ifndef APACHE_READDIR_H
-#define APACHE_READDIR_H
-    
-#ifdef WIN32
-    
-#include <io.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <sys/types.h>
-    
-/* struct dirent - same as Unix */ 
+/* ====================================================================
+ * The Apache Software License, Version 1.1
+ *
+ * Copyright (c) 2000 The Apache Software Foundation.  All rights
+ * reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in
+ *    the documentation and/or other materials provided with the
+ *    distribution.
+ *
+ * 3. The end-user documentation included with the redistribution,
+ *    if any, must include the following acknowledgment:
+ *       "This product includes software developed by the
+ *        Apache Software Foundation (http://www.apache.org/)."
+ *    Alternately, this acknowledgment may appear in the software itself,
+ *    if and wherever such third-party acknowledgments normally appear.
+ *
+ * 4. The names "Apache" and "Apache Software Foundation" must
+ *    not be used to endorse or promote products derived from this
+ *    software without prior written permission. For written
+ *    permission, please contact apa...@apache.org.
+ *
+ * 5. Products derived from this software may not be called "Apache",
+ *    nor may "Apache" appear in their name, without prior written
+ *    permission of the Apache Software Foundation.
+ *
+ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
+ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
+ * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+ * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ * ====================================================================
+ *
+ * This software consists of voluntary contributions made by many
+ * individuals on behalf of the Apache Software Foundation.  For more
+ * information on the Apache Software Foundation, please see
+ * <http://www.apache.org/>.
+ *
+ * Portions of this software are based upon public domain software
+ * originally written at the National Center for Supercomputing Applications,
+ * University of Illinois, Urbana-Champaign.
+ */  
+    
+/*
+ * Structures and types used to implement opendir/readdir/closedir
+ * on Windows 95/NT.
+ */ 
+    
+#ifndef APACHE_READDIR_H
+#define APACHE_READDIR_H
+    
+#ifdef WIN32
+    
+#include <io.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/types.h>
+    
+/* struct dirent - same as Unix */ 
     struct dirent {
-        long d_ino;            /* inode (always 1 in WIN32) */
-         off_t d_off;          /* offset to this dirent */
-         unsigned short d_reclen;      /* length of d_name */
-         char d_name[_MAX_FNAME + 1];  /* filename (null terminated) */
- };
-
-/* typedef DIR - not the same as Unix */ 
+       long d_ino;             /* inode (always 1 in WIN32) */
+        off_t d_off;           /* offset to this dirent */
+        unsigned short d_reclen;       /* length of d_name */
+        char d_name[_MAX_FNAME + 1];   /* filename (null terminated) */
+};
+
+/* typedef DIR - not the same as Unix */ 
     typedef struct {
-        long handle;           /* _findfirst/_findnext handle */
-         short offset;         /* offset into directory */
-         short finished;       /* 1 if there are not more files */
-         struct _finddata_t fileinfo;  /* from _findfirst/_findnext */
-        char *dir;             /* the dir we are reading */
-         struct dirent dent;   /* the dirent to return */
- } DIR;
-
-/* Function prototypes */ 
+       long handle;            /* _findfirst/_findnext handle */
+        short offset;          /* offset into directory */
+        short finished;        /* 1 if there are not more files */
+        struct _finddata_t fileinfo;   /* from _findfirst/_findnext */
+       char *dir;              /* the dir we are reading */
+        struct dirent dent;    /* the dirent to return */
+} DIR;
+
+/* Function prototypes */ 
     DIR * opendir(const char *);
- struct dirent *readdir(DIR *);
- int closedir(DIR *);
-
-#endif /* WIN32 */
-    
-#endif /* ndef APACHE_READDIR_H */
+struct dirent *readdir(DIR *);
+int closedir(DIR *);
+
+#endif /* WIN32 */
+    
+#endif /* ndef APACHE_READDIR_H */

Reply via email to