[CWB] [CQPWeb] problem of memory

Hardie, Andrew a.hardie at lancaster.ac.uk
Wed Feb 8 13:45:40 CET 2012


>>>

I guess it's about time that we require full ANSI C + POSIX compliance and throw out all the #ifdef's that work around bugs in other platforms.

<<<

Certainly in this case, since the MAP_FAILED macro is used all over the place, and only here is it protected by an #ifdef. Might be worth sticking a swift #ifndef MAP_FAILED #define MAP_FAILED ((void *)-1) #endif into globals.h though, just in case. (We should be using void * instead of caddr_t for values returned by mmap(), anyway.)

Andrew.


More information about the CWB mailing list