diff options
author | unknown <monty@mashka.mysql.fi> | 2003-03-11 00:30:35 +0200 |
---|---|---|
committer | unknown <monty@mashka.mysql.fi> | 2003-03-11 00:30:35 +0200 |
commit | 80f6466c85df3e5b01462c280db96c600f9147be (patch) | |
tree | 1c1816e4766ae65ff4aa41881e6561dbf367690e /cmd-line-utils | |
parent | 401f3fb41807062707ae949a9554765db3ba9351 (diff) | |
download | mariadb-git-80f6466c85df3e5b01462c280db96c600f9147be.tar.gz |
Portability fixes
cmd-line-utils/libedit/el.c:
Portability fix
configure.in:
Portability fix
(Don't call AC_PROG_CC twice)
sql/mysqld.cc:
Move stack checking to right position
Diffstat (limited to 'cmd-line-utils')
-rw-r--r-- | cmd-line-utils/libedit/el.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/cmd-line-utils/libedit/el.c b/cmd-line-utils/libedit/el.c index d436d113419..76b17aba0cf 100644 --- a/cmd-line-utils/libedit/el.c +++ b/cmd-line-utils/libedit/el.c @@ -369,6 +369,14 @@ el_line(EditLine *el) static const char elpath[] = "/.editrc"; +#if defined(MAXPATHLEN) +#define LIBEDIT_MAXPATHLEN MAXPATHLEN +#elif defined(PATH_MAX) +#define LIBEDIT_MAXPATHLEN PATH_MAX +#else +#define LIBEDIT_MAXPATHLEN 1024 +#endif + /* el_source(): * Source a file */ @@ -377,7 +385,7 @@ el_source(EditLine *el, const char *fname) { FILE *fp; size_t len; - char *ptr, path[MAXPATHLEN]; + char *ptr, path[LIBEDIT_MAXPATHLEN]; fp = NULL; if (fname == NULL) { |