Simply finding a file name in mtree format to avoid redundant code.