(cherry picked from commit 4c877b63e44966f5373c264a3c82556ac9883761) Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>