More backported fixes.