B248 Patch 6.1.1

Should work with B249 and hopefully upcoming luaJIT.