stabilize #1564, fix #1564 properly