lua-users home
lua-l archive

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


>> kernelinfo = io.open("/proc/version"):read()

what if io.open fails? won't you get a "trying to index a nil value" or
similar error?

would the following work and throw a more reasonable error message? 
kernelinfo = assert(io.open("/proc/version")):read()


steffenj