Apply vanilla 3.9.5 patches
Merge branch 'master' into vanilla-ravion