Fixes segmentation fault in fileutils while listing files