Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | "extern" declarations inside function bodies are not every compiler's favorite, so move to global scope. Additionally, at least under Unix environment use <unistd.h> to get the proper prototype instead of using a K&R-style own declaration. (CVS 4190) |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
5955a77d6c902dc65897ba19d6e06db3 |
User & Date: | rse 2007-07-30 18:31:53.000 |
Context
2007-07-30
| ||
18:55 | Fix ticket #2439: the FTS1 and FTS2 extensions use the non-standard, unportable and highly deprecated <malloc.h> header on all platforms except Apple Mac OS X. The <malloc.h> actually is never required on any OS with an at least partly POSIX-conforming API as the malloc(3) & friends functions officially live in <stdlib.h> since over 10 years. Under some platform like FreeBSD the inclusion of <malloc.h> since a few years even causes an "#error" and this way a build failure. So, just get rid of the bad <malloc.h> usage in FTS1 and FTS2 extensions at all and stick with <stdlib.h> there only. (CVS 4191) (check-in: 3f9a666143 user: rse tags: trunk) | |
18:31 | "extern" declarations inside function bodies are not every compiler's favorite, so move to global scope. Additionally, at least under Unix environment use <unistd.h> to get the proper prototype instead of using a K&R-style own declaration. (CVS 4190) (check-in: 5955a77d6c user: rse tags: trunk) | |
18:26 | Get rid of the following compile-time warnings: tool/mkkeywordhash.c:353: warning: array subscript has type 'char' tool/mkkeywordhash.c:354: warning: array subscript has type 'char' (CVS 4189) (check-in: c01d794479 user: rse tags: trunk) | |
Changes
Changes to tool/lemon.c.
︙ | ︙ | |||
14 15 16 17 18 19 20 21 22 23 24 25 26 27 | #include <assert.h> #ifndef __WIN32__ # if defined(_WIN32) || defined(WIN32) # define __WIN32__ # endif #endif /* #define PRIVATE static */ #define PRIVATE #ifdef TEST #define MAXRHS 5 /* Set low to exercise exception code */ #else | > > > > > > | 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #include <assert.h> #ifndef __WIN32__ # if defined(_WIN32) || defined(WIN32) # define __WIN32__ # endif #endif #ifdef __WIN32__ extern int access(); #else #include <unistd.h> #endif /* #define PRIVATE static */ #define PRIVATE #ifdef TEST #define MAXRHS 5 /* Set low to exercise exception code */ #else |
︙ | ︙ | |||
2900 2901 2902 2903 2904 2905 2906 | char *argv0; char *name; int modemask; { char *pathlist; char *path,*cp; char c; | < | 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 | char *argv0; char *name; int modemask; { char *pathlist; char *path,*cp; char c; #ifdef __WIN32__ cp = strrchr(argv0,'\\'); #else cp = strrchr(argv0,'/'); #endif if( cp ){ |
︙ | ︙ |