Fixed the definition of global variable.