Why cast to non-const (char *) ?