Fix some CGL issues