fixed subdirectory bug in req_file