Added support for IO::String and "in memory" files, other minor fixes