[RFC] Transform global variable really_exiting into static.

Transform global variable really_exiting into static and some minor style changes.

Comments are welcome.
That comment is related to really_exiting