Fixed a problem while sorting dirlists - not seen until now
First nearly working version