performCriticalExit() must not be defined static.
Note that static global functions are only visible within the specific source file. Removed static keyword.