cw.c: have parameter return NULL, not "-1", on failure.