We really need test cases verifying this (actually, test cases verifying every unit of functionality added in this patch!), but especially this branch.

Please add test cases for this, I'm happy to help if you need assistance.