1. some more memory leaks fixed
2. preparation for buchber product criterion check