Bug fix - the GTK+ file selection dialog causes an infinite malloc() loop.

This bug affects mtPaint and gtkedit - when the file selection dialog shows up, the application freezes and enters an infinite loop of memory allocation, because it tries to read the contents of /, again and again. It seems rewinddir() doesn't work with luufs (i.e readdir() continues to the next entry) and it's not a system call, so FUSE cannot support it.

This patch replaces the rewinddir() call with another opendir() - ugly, but that's the simplest solution to this problem.