Fix a crash on exit if build with -fstack-protector-all.
PR: 234607 Submitted by: rozhuk.im@gmail.com