[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: require bug?
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Thu, 25 Sep 2008 14:52:13 -0300
> The problem is, the 'app/geresim/prerock/lua' directory contains both a
> 'corr' directory and a 'corr.lua' file.
What is your package.path?
> The problem is, apparently fopen succeeds when trying to open a
> directory but later on, when the file is actually fread from, this
> error happens. I changed 'readable' so that it will fail if reading
> from the file fails:
That should work in modern Unix systems. luaL_loadfile has similar code.
In old Unix systems, directories could be read like ordinary files.
(Ah, the good old days...)