version 1.22, 2015/01/16 06:40:07 |
version 1.23, 2015/11/05 09:48:21 |
|
|
expanded = 1; |
expanded = 1; |
} |
} |
|
|
if (q != NULL) |
free(q); |
xfree(q); |
|
} |
} |
|
|
if (!expanded && default_args != NULL) { |
if (!expanded && default_args != NULL) { |
|
|
return (buf_release(buf)); |
return (buf_release(buf)); |
|
|
bad: |
bad: |
if (q != NULL) |
free(q); |
xfree(q); |
|
cvs_log(LP_NOTICE, "%s contains malformed command '%s'", file, cmd); |
cvs_log(LP_NOTICE, "%s contains malformed command '%s'", file, cmd); |
buf_free(buf); |
buf_free(buf); |
return (NULL); |
return (NULL); |
|
|
case CVS_TRIGGER_TAGINFO: |
case CVS_TRIGGER_TAGINFO: |
case CVS_TRIGGER_VERIFYMSG: |
case CVS_TRIGGER_VERIFYMSG: |
if ((r = cvs_exec(cmd, NULL, 1)) != 0) { |
if ((r = cvs_exec(cmd, NULL, 1)) != 0) { |
xfree(cmd); |
free(cmd); |
return (r); |
return (r); |
} |
} |
break; |
break; |
|
|
(void)cvs_exec(cmd, in, 1); |
(void)cvs_exec(cmd, in, 1); |
break; |
break; |
} |
} |
xfree(cmd); |
free(cmd); |
} |
} |
|
|
return (0); |
return (0); |
|
|
} |
} |
} |
} |
|
|
if (nline != NULL) |
free(nline); |
xfree(nline); |
|
|
|
if (defaultline != NULL) { |
if (defaultline != NULL) { |
if (!match) { |
if (!match) { |
|
|
tline->line = defaultline; |
tline->line = defaultline; |
TAILQ_INSERT_HEAD(list, tline, flist); |
TAILQ_INSERT_HEAD(list, tline, flist); |
} else |
} else |
xfree(defaultline); |
free(defaultline); |
} |
} |
|
|
(void)fclose(fp); |
(void)fclose(fp); |
|
|
if (TAILQ_EMPTY(list)) { |
if (TAILQ_EMPTY(list)) { |
xfree(list); |
free(list); |
list = NULL; |
list = NULL; |
} |
} |
|
|
|
|
|
|
bad: |
bad: |
cvs_log(LP_NOTICE, "%s: malformed line %d", file, lineno); |
cvs_log(LP_NOTICE, "%s: malformed line %d", file, lineno); |
|
free(defaultline); |
if (defaultline != NULL) |
|
xfree(defaultline); |
|
cvs_trigger_freelist(list); |
cvs_trigger_freelist(list); |
|
|
(void)fclose(fp); |
(void)fclose(fp); |
|
|
|
|
while ((line = TAILQ_FIRST(list)) != NULL) { |
while ((line = TAILQ_FIRST(list)) != NULL) { |
TAILQ_REMOVE(list, line, flist); |
TAILQ_REMOVE(list, line, flist); |
xfree(line->line); |
free(line->line); |
xfree(line); |
free(line); |
} |
} |
|
|
xfree(list); |
free(list); |
} |
} |
|
|
void |
void |
|
|
while ((fi = TAILQ_FIRST(list)) != NULL) { |
while ((fi = TAILQ_FIRST(list)) != NULL) { |
TAILQ_REMOVE(list, fi, flist); |
TAILQ_REMOVE(list, fi, flist); |
|
|
if (fi->file_path != NULL) |
free(fi->file_path); |
xfree(fi->file_path); |
free(fi->file_wd); |
if (fi->file_wd != NULL) |
free(fi->crevstr); |
xfree(fi->file_wd); |
free(fi->nrevstr); |
if (fi->crevstr != NULL) |
free(fi->tag_new); |
xfree(fi->crevstr); |
free(fi->tag_old); |
if (fi->nrevstr != NULL) |
free(fi); |
xfree(fi->nrevstr); |
|
if (fi->tag_new != NULL) |
|
xfree(fi->tag_new); |
|
if (fi->tag_old != NULL) |
|
xfree(fi->tag_old); |
|
|
|
xfree(fi); |
|
} |
} |
} |
} |
|
|