Fixed some global variables definitions