applied Benjamin Riefenstahl's patches for building on Windows

This commit is contained in:
vdvo
2002-05-27 16:45:32 +00:00
parent a80a9680fe
commit 79fe4b68df
15 changed files with 76 additions and 113 deletions

View File

@@ -20,12 +20,8 @@
Arturo Tena <arturo@directmail.org>
*/
#if !(defined( __BORLANDC__ ) || defined( __WIN32__ ))
#include "config.h"
#include "cole.h"
#else
#include "cole.h.in"
#endif
#include "internal.h"
#include <stdlib.h>
@@ -193,7 +189,7 @@ cole_umount (COLEFS *colefilesystem, COLERRNO *colerrno)
if (colerrno != NULL) *colerrno = COLE_ECLOSEFILE;
ret = 1;
}
#if defined(__WIN32__) || (__BORLANDC__)
#if defined(WIN32)
if (remove (colefilesystem->sbfilename) && !ret) {
if (colerrno != NULL) *colerrno = COLE_EREMOVE;
ret = 1;
@@ -247,6 +243,9 @@ __cole_print_tree_indir(COLEDIR *cd, void *info, COLERRNO *colerrno)
* Modify colerrno comment in the functions that call it,
* ie. cole_print_tree().
*/
(void) cd; /*UNUSED*/
(void) colerrno; /*UNUSED*/
(*((long*)info))++;
return 0;
}
@@ -259,6 +258,9 @@ __cole_print_tree_outdir(COLEDIR *cd, void *info, COLERRNO *colerrno)
* Modify colerrno comment in the functions that call it,
* ie. cole_print_tree().
*/
(void) cd; /*UNUSED*/
(void) colerrno; /*UNUSED*/
(*((long*)info))--;
return 0;
}
@@ -273,6 +275,9 @@ __cole_print_tree_inroot(COLEDIR *cd, void *info, COLERRNO *colerrno)
*/
char *entry_name;
(void) info; /*UNUSED*/
(void) colerrno; /*UNUSED*/
printf ("DIR ");
printf (" %7zu", cole_dir_getsize (cd));
printf (" %08lx-%08lx %08lx-%08lx",
@@ -301,6 +306,8 @@ __cole_print_tree_indirentry(COLEDIRENT *cde, void *info, COLERRNO *colerrno)
long level;
long i;
(void) colerrno; /*UNUSED*/
level = *((long*)info);
for (i = 0; i < level; i++) {
if (i == level - 1)
@@ -405,6 +412,8 @@ cole_opendir_direntry (COLEDIRENT *coledirentry, COLERRNO *colerrno)
int
cole_closedir (COLEDIR *coledir, COLERRNO *colerrno)
{
(void) colerrno; /*UNUSED*/
free (coledir);
return 0;
@@ -1136,6 +1145,8 @@ cole_locate_filename (COLEFS *colefilesystem, char *filename,
static int
__cole_locate_filename_visitdir (COLEDIR *cd, void *info)
{
(void) cd; /*UNUSED*/
return ((struct __cole_locate_filenameinfo *)info)->visitdir;
}