Several bug fixes / see d.o 7.x-2.x-dev