aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lfs.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lfs.c b/src/lfs.c
index 8b4cfd2..68040d4 100644
--- a/src/lfs.c
+++ b/src/lfs.c
@@ -354,11 +354,10 @@ static int lfs_g_setmode (lua_State *L, FILE *f, int arg) {
354 for (i = 0; modenames[i] != NULL; i++) { 354 for (i = 0; modenames[i] != NULL; i++) {
355 if (mode[i] == res) { 355 if (mode[i] == res) {
356 lua_pushstring(L, modenames[i]); 356 lua_pushstring(L, modenames[i]);
357 goto exit; 357 return 2;
358 } 358 }
359 } 359 }
360 lua_pushnil(L); 360 lua_pushnil(L);
361 exit:
362 return 2; 361 return 2;
363 } else { 362 } else {
364 int en = errno; 363 int en = errno;