updated cd.c