Various features (cont. fixes)

Some fixes in addition to PR:#520.