diff --git a/koboldcpp.py b/koboldcpp.py index 5446477a8..ec771ece4 100644 --- a/koboldcpp.py +++ b/koboldcpp.py @@ -210,7 +210,7 @@ maxctx = 2048 maxlen = 128 modelbusy = False defaultport = 5001 -KcppVersion = "1.26" +KcppVersion = "1.27" class ServerRequestHandler(http.server.SimpleHTTPRequestHandler): sys_version = "" diff --git a/otherarch/rwkv_v3.cpp b/otherarch/rwkv_v3.cpp index 04d228eee..60ae4f1bf 100644 --- a/otherarch/rwkv_v3.cpp +++ b/otherarch/rwkv_v3.cpp @@ -22,8 +22,8 @@ #include // fstat #ifdef WIN32 -#define stat64 _stat64 -#define fstat64 _fstat64 +#define stat _stat64 +#define fstat _fstat64 #endif // --- Error handling --- @@ -477,8 +477,8 @@ struct rwkv_context * rwkv_init_from_file(const char * file_path, const uint32_t rwkv_file_guard file_guard { file }; // Be very careful when changing this code. It must support files larger than 2 GB by using 64-bit functions to the get file length. - struct stat64 file_stat; - RWKV_ASSERT_NULL_MSG(RWKV_ERROR_FILE | RWKV_ERROR_FILE_STAT, fstat64(fileno(file), &file_stat) == 0, "Failed to stat file %s", file_path); + struct stat file_stat; + RWKV_ASSERT_NULL_MSG(RWKV_ERROR_FILE | RWKV_ERROR_FILE_STAT, fstat(fileno(file), &file_stat) == 0, "Failed to stat file %s", file_path); int32_t magic; RWKV_ASSERT_NULL(RWKV_ERROR_FILE, read_int32(file, &magic, "magic"));