fixed up path allocation stuff for reader