prevent generate_filelist() from failing if only one file was found due to the current linked-list logic

This comes from the way I use trinity currently, only opening one specific
character device. The linked-list implementation by default points ->next to
the first element so that if only one element is in the list, the loop logic
fails to add that file.