Recursive cherry-pick of 517b73ebb2490494e07caed47594c75f223b3831 from vampiricwulf/doushio