fixed dlopen so it supports the chunked file read

added fix for lazy file loading (no head requests until necessary)