فهرست منبع

revert: f:read的buff不需要太大

Wendal Chen 2 سال پیش
والد
کامیت
59978db944
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      lua/src/liolib.c

+ 1 - 1
lua/src/liolib.c

@@ -571,7 +571,7 @@ static int test_eof (lua_State *L, FILE *f) {
 static int read_line (lua_State *L, FILE *f, int chop) {
   luaL_Buffer b;
   int c = '\0';
-  #define READLINE_BUFF_SIZE (2048)
+  #define READLINE_BUFF_SIZE (1024)
   luaL_buffinitsize(L, &b, READLINE_BUFF_SIZE);
   // luaL_buffinit(L, &b);
   while (c != EOF && c != '\n') {  /* repeat until end of line */