From 0deaeaa80c40531d59ca39e17e7f718430efcb4f Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Sat, 5 Feb 2005 19:22:03 +0000 Subject: Fixed some compiler errors on WIN32 (STR #647) src/scandir_win32.c: - Add casts for malloc and calloc calls. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4017 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- CHANGES | 1 + src/scandir_win32.c | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CHANGES b/CHANGES index ba7bff52e..0ee9f4310 100644 --- a/CHANGES +++ b/CHANGES @@ -1,5 +1,6 @@ CHANGES IN FLTK 1.1.7 + - Fixed some compiler errors on WIN32 (STR #647) - FLUID didn't update the widget panel X/Y/W/H values when moving the selected window (STR #701) - FLUID didn't use the label type constant names for diff --git a/src/scandir_win32.c b/src/scandir_win32.c index f02c72b23..39922cfd1 100644 --- a/src/scandir_win32.c +++ b/src/scandir_win32.c @@ -1,5 +1,5 @@ /* - * "$Id: scandir_win32.c,v 1.11.2.4.2.9 2004/04/11 04:39:00 easysw Exp $" + * "$Id$" * * WIN32 scandir function for the Fast Light Tool Kit (FLTK). * @@ -43,7 +43,7 @@ int fl_scandir(const char *dirname, struct dirent ***namelist, unsigned long ret; len = strlen(dirname); - findIn = malloc(len+5); + findIn = (char *)malloc(len+5); if (!findIn) return -1; @@ -72,7 +72,7 @@ int fl_scandir(const char *dirname, struct dirent ***namelist, } if (!select || (*select)(selectDir)) { if (nDir==NDir) { - struct dirent **tempDir = calloc(sizeof(struct dirent*), NDir+33); + struct dirent **tempDir = (struct dirent **)calloc(sizeof(struct dirent*), NDir+33); if (NDir) memcpy(tempDir, dir, sizeof(struct dirent*)*NDir); if (dir) free(dir); dir = tempDir; @@ -104,5 +104,5 @@ int fl_scandir(const char *dirname, struct dirent ***namelist, #endif /* - * End of "$Id: scandir_win32.c,v 1.11.2.4.2.9 2004/04/11 04:39:00 easysw Exp $". + * End of "$Id$". */ -- cgit v1.2.3