diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-09-13 17:12:14 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-09-13 17:12:14 -0300 |
commit | f45cba42b5c32758337f62c56e98fdb85a9f4af2 (patch) | |
tree | 036ed7731e64f502eb0d94552ab266b0ae358907 | |
parent | 2628a424801de3562777a059e599c5e7255965a1 (diff) | |
download | lua-f45cba42b5c32758337f62c56e98fdb85a9f4af2.tar.gz lua-f45cba42b5c32758337f62c56e98fdb85a9f4af2.tar.bz2 lua-f45cba42b5c32758337f62c56e98fdb85a9f4af2.zip |
details for OLD_ANSI
-rw-r--r-- | liolib.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: liolib.c,v 1.81 2000/09/12 13:58:37 roberto Exp roberto $ | 2 | ** $Id: liolib.c,v 1.82 2000/09/12 18:41:55 roberto Exp roberto $ |
3 | ** Standard I/O (and system) library | 3 | ** Standard I/O (and system) library |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -21,6 +21,8 @@ | |||
21 | #ifndef OLD_ANSI | 21 | #ifndef OLD_ANSI |
22 | #include <errno.h> | 22 | #include <errno.h> |
23 | #include <locale.h> | 23 | #include <locale.h> |
24 | #define realloc(b,s) ((b) == NULL ? malloc(s) : (realloc)(b, s)) | ||
25 | #define free(b) if (b) (free)(b) | ||
24 | #else | 26 | #else |
25 | /* no support for locale and for strerror: fake them */ | 27 | /* no support for locale and for strerror: fake them */ |
26 | #define setlocale(a,b) ((void)a, strcmp((b),"C")==0?"C":NULL) | 28 | #define setlocale(a,b) ((void)a, strcmp((b),"C")==0?"C":NULL) |