merge of the actual 3.x into 3.1 branch