gaochunzy / mongoose

Automatically exported from code.google.com/p/mongoose
MIT License
1 stars 0 forks source link

error compiling mongoose non existing size_t #387

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
If you try to compile a program with mongoose, where the first included file in 
mongoose.h, then program it's not compilable... it gives the following error:

mongoose.h:147: error: ‘size_t’ has not been declared
mongoose.h:160: error: ‘size_t’ has not been declared
mongoose.h:187: error: ‘size_t’ has not been declared
mongoose.h:188: error: ‘size_t’ has not been declared
mongoose.h:202: error: ‘size_t’ has not been declared

Solution it's easy, before including mongoose.h include stdlib.h and the 
program compiles ok... but I think that mongoose.h should be "auto sufficient", 
if it needs size_t declared, then include std lib.h, or define the type 
directly....

It's a very low issue.

Regards

Original issue reported on code.google.com by ricondo....@gmail.com on 30 Sep 2012 at 2:59

GoogleCodeExporter commented 9 years ago
mongoose.h does #include <stddef.h>
By ISO C 99 standard, 7.17, stddef.h should contain the definition of size_t.
What platform are you using? It appears to be non-conforming.

Original comment by valenok on 30 Sep 2012 at 3:21

GoogleCodeExporter commented 9 years ago
I was compiling in Debian 5 and Debian 6... but I were trying with Mongoose 
3.0... It doesn't happens in Mongoose 3.3... sorry and close issue.

Original comment by uba...@hotmail.com on 2 Oct 2012 at 12:31

GoogleCodeExporter commented 9 years ago

Original comment by valenok on 10 Feb 2013 at 3:13