Found out why it does it. It's not easy to fix, though. Or, more accurately, I can fix it, but it'll break several other things.

I don't have the time right now to implement a proper fix, sorry...
_________________________
-- roger