Define a fallback PATH_MAX if not available

PATH_MAX is optional in POSIX, and it is not available on GNU/Hurd.
While it could be possible to not rely on PATH_MAX, for now provide a
fallback definition (which should be safe enough) to get quickjs built
on GNU/Hurd.
This commit is contained in:
Pino Toscano 2024-06-09 09:23:49 +02:00 committed by Charlie Gordon
parent 8624b5c6f0
commit 012451d5f3

View file

@ -78,6 +78,10 @@ typedef sig_t sighandler_t;
#include "list.h"
#include "quickjs-libc.h"
#if !defined(PATH_MAX)
#define PATH_MAX 4096
#endif
/* TODO:
- add socket calls
*/