repair globals.c