backport to 5.3