COMP: Fix warnings on Borland dashboards...

This commit is contained in:
David Cole 2006-05-23 12:38:22 -04:00
parent 35334d01cd
commit 13a68cd978
6 changed files with 20 additions and 8 deletions

View File

@ -67,6 +67,7 @@ FOREACH(file
"ctype.h"
"fnmatch.h"
"inttypes.h"
"io.h"
"libgen.h"
"memory.h"
"sys/mkdev.h"

View File

@ -31,8 +31,9 @@
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#ifdef _MSC_VER
#include <io.h>
#ifdef HAVE_IO_H
# include <io.h>
#endif
struct tar_dev

View File

@ -70,11 +70,7 @@ static char rcsid[] = "$OpenBSD: fnmatch.c,v 1.6 1998/03/19 00:29:59 millert Exp
#define RANGE_NOMATCH 0
#define RANGE_ERROR (-1)
#ifdef NO_IBM_COMPILER_HORKAGE
static int rangematch (const char *, char, int, char **);
#else
static int rangematch ();
#endif
int
fnmatch(pattern, string, flags)
@ -195,7 +191,8 @@ rangematch(pattern, test, flags, newp)
* consistency with the regular expression syntax.
* J.T. Conklin (conklin@ngai.kaleida.com)
*/
if ((negate = (*pattern == '!' || *pattern == '^')))
negate = (*pattern == '!' || *pattern == '^');
if (negate)
++pattern;
if (flags & FNM_CASEFOLD)

View File

@ -30,6 +30,9 @@
/* Define to 1 if you have the <inttypes.h> header file. */
#cmakedefine HAVE_INTTYPES_H @HAVE_INTTYPES_H@
/* Define to 1 if you have the <io.h> header file. */
#cmakedefine HAVE_IO_H @HAVE_IO_H@
/* Define to 1 if you have the `lchown' function. */
#cmakedefine HAVE_LCHOWN @HAVE_LCHOWN@

View File

@ -470,11 +470,13 @@ tar_extract_hardlink(TAR * t, char *realname)
return -1;
}
#ifndef WIN32
if (pathname)
{
free(pathname);
}
return 0;
#endif
}
@ -545,11 +547,13 @@ tar_extract_symlink(TAR *t, char *realname)
return -1;
}
#ifndef WIN32
if (pathname)
{
free(pathname);
}
return 0;
#endif
}
@ -620,11 +624,13 @@ tar_extract_chardev(TAR *t, char *realname)
return -1;
}
#ifndef WIN32
if (pathname)
{
free(pathname);
}
return 0;
#endif
}
@ -694,11 +700,13 @@ tar_extract_blockdev(TAR *t, char *realname)
return -1;
}
#ifndef WIN32
if (pathname)
{
free(pathname);
}
return 0;
#endif
}
@ -867,9 +875,11 @@ tar_extract_fifo(TAR *t, char *realname)
return -1;
}
#ifndef WIN32
if (pathname)
{
free(pathname);
}
return 0;
#endif
}

View File

@ -24,7 +24,7 @@
# include <stdlib.h>
#endif
#if defined ( _MSC_VER) || defined(__WATCOMC__)
#ifdef HAVE_IO_H
#include <io.h>
//Yogi: hack. this should work on windows where there is no O_ACCMODE defined
#ifndef O_ACCMODE