fixing dg.variables.c