Building Eterm - please more help

Jean-Claude Gervais jc.gervais@videotron.ca
Thu Oct 31 06:18:00 GMT 2002


>If PATH_MAX is not defined it defaults to 0 in
>preprocessor conditionals.
>That's just the definition of the C language.

What? Are you sure? I always thought the symbols was UNDEFINED, and not 0.

So if you're using it in code and it is not defined, it is like there is
NOTHING there, for example:

If the symbol PATH_MAX is undefined, the following statement

if ( PATH_MAX > 200 ) {
}

will get expanded by the pre-processor to

if (  > 200 ) {
}

Which is syntactically incorrect. Maybe I misunderstood your assertion...

BY THE WAY, why not use _MAX_PATH instead? It is commonly defined by all
compiler vendors.




More information about the Cygwin-xfree mailing list