patch upstream to 3.4.11 (part two)