[core] fix listing of devices when all 26 drive letters are in use

* Issue reported by Alex