diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2021-11-26 21:22:20 -0800 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2021-11-26 21:22:20 -0800 |
commit | 6b6fe7ce729989979d32e804a18225f02644c1ac (patch) | |
tree | 11f98a5fab954fc04917b9f9a6ee3794ba1c2a76 | |
parent | db7202ccfd30857d18c48a2dcf37b0a2ae95807a (diff) | |
download | teliva-6b6fe7ce729989979d32e804a18225f02644c1ac.tar.gz |
periodic cleanup of warnings
-rw-r--r-- | src/lua.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lua.c b/src/lua.c index b0662f7..f4e5265 100644 --- a/src/lua.c +++ b/src/lua.c @@ -454,7 +454,7 @@ static void save_image (lua_State *L) { for (lua_pushnil(L); lua_next(L, table) != 0; lua_pop(L, 1)) { const char* key = lua_tostring(L, -2); if (strcmp(key, "__teliva_undo") == 0) { - fprintf(out, " %s = %d\n", key, lua_tointeger(L, -1)); + fprintf(out, " %s = %ld\n", key, lua_tointeger(L, -1)); continue; } const char* value = lua_tostring(L, -1); @@ -641,9 +641,9 @@ void recent_changes (lua_State *L) { while (!quit) { /* refresh state after each operation so we pick up modifications */ lua_getglobal(L, "teliva_program"); - int history_array = lua_gettop(L); + history_array = lua_gettop(L); assert(history_array == 1); - int history_array_size = luaL_getn(L, history_array); + history_array_size = luaL_getn(L, history_array); render_recent_changes(L, history_array, cursor, history_array_size); int c = getch(); switch (c) { |