refix for #52

* "undo" a087de85e7e62cacbeb96e2763ed905a0016448a
* more general fix (previous one was not done in the right place)
minor change (in debug mode)