aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lfs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lfs.c b/src/lfs.c
index f0a0db9..f93db95 100644
--- a/src/lfs.c
+++ b/src/lfs.c
@@ -275,7 +275,7 @@ static int get_dir(lua_State * L)
275 size_t size = LFS_MAXPATHLEN; /* initial buffer size */ 275 size_t size = LFS_MAXPATHLEN; /* initial buffer size */
276 int result; 276 int result;
277 while (1) { 277 while (1) {
278 char *path2 = realloc(path, size); 278 char *path2 = (char *)realloc(path, size);
279 if (!path2) { /* failed to allocate */ 279 if (!path2) { /* failed to allocate */
280 result = pusherror(L, "get_dir realloc() failed"); 280 result = pusherror(L, "get_dir realloc() failed");
281 break; 281 break;
@@ -1065,7 +1065,7 @@ static int push_link_target(lua_State * L)
1065 int tsize = 0, size = 256; /* size = initial buffer capacity */ 1065 int tsize = 0, size = 256; /* size = initial buffer capacity */
1066 int ok = 0; 1066 int ok = 0;
1067 while (!ok) { 1067 while (!ok) {
1068 char *target2 = realloc(target, size); 1068 char *target2 = (char *)realloc(target, size);
1069 if (!target2) { /* failed to allocate */ 1069 if (!target2) { /* failed to allocate */
1070 break; 1070 break;
1071 } 1071 }