(cherry picked from commit 0b43b1f091f19b875a87f08acbc5621bc749b3d8) (cherry picked from commit cfc205f438233987745faef61fd80336d5143394)