lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> The function luaL_loadfilex ends with these lines:
> 
>   readstatus = ferror(lf.f);
>   if (filename) fclose(lf.f);  /* close file (even in case of errors) */
>   if (readstatus) {
>     lua_settop(L, fnameindex);  /* ignore results from 'lua_load' */
>     return errfile(L, "read", fnameindex);
>   }
> 
> 
> I give a candy to anyone who sees the bug ;-)

I still fail to see the bug. What is the problem if the error reported
is a real error in 'fclose' instead of the previous error? More to the
point, do you have a concrete example where this issue causes any
harm or confusion?

-- Roberto
_______________________________________________
lua-l mailing list -- lua-l@lists.lua.org
To unsubscribe send an email to lua-l-leave@lists.lua.org