Thanks for reporting the issue.
Looks like there is a bug, but at the moment I'm not quite sure where exactly it is, and how to fix it in a right manner. I'll take a look at this in the near future and post the conclusion.
UPD.: It seems that I located and fixed the bug. But it will take some additional time for me to make sure that it's really fixed now.