Fixes. Many fixes. issue937-951