first check if the the file was successfully opened, then try opening the other files
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@4010 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
b6834a014b
commit
f359cf7b51
1 changed files with 4 additions and 3 deletions
|
@ -968,7 +968,11 @@ static void xhtml_do_top_file(xhtmlfile * file, paragraph * sourceform)
|
||||||
paragraph *p;
|
paragraph *p;
|
||||||
char fname[_MAX_PATH];
|
char fname[_MAX_PATH];
|
||||||
int done = FALSE;
|
int done = FALSE;
|
||||||
|
|
||||||
FILE *fp = fopen(file->filename, "w");
|
FILE *fp = fopen(file->filename, "w");
|
||||||
|
if (fp == NULL)
|
||||||
|
fatal(err_cantopenw, file->filename);
|
||||||
|
|
||||||
ustrtoa(conf.chm_toc_file, fname, _MAX_PATH);
|
ustrtoa(conf.chm_toc_file, fname, _MAX_PATH);
|
||||||
if(*fname)
|
if(*fname)
|
||||||
{
|
{
|
||||||
|
@ -987,9 +991,6 @@ static void xhtml_do_top_file(xhtmlfile * file, paragraph * sourceform)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
chm_ind = NULL;
|
chm_ind = NULL;
|
||||||
if (fp == NULL)
|
|
||||||
fatal(err_cantopenw, file->filename);
|
|
||||||
|
|
||||||
|
|
||||||
/* Do the title -- only one allowed */
|
/* Do the title -- only one allowed */
|
||||||
for (p = sourceform; p && !done; p = p->next)
|
for (p = sourceform; p && !done; p = p->next)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue