3.5.x backport issue 3314