updated reference to filenames[] debug output