summaryrefslogtreecommitdiffstats
path: root/src/hardcopy.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2010-07-31 16:44:19 +0200
committerBram Moolenaar <Bram@vim.org>2010-07-31 16:44:19 +0200
commita9d52e3b7925ef119b5d0d9fca14faac634effb0 (patch)
tree151c52ad2e282b8e264aee2fc7af3db76d8c2071 /src/hardcopy.c
parenta26559b553079c3959ee142a010b2e000c180323 (diff)
Fixes for coverity warnings.
Diffstat (limited to 'src/hardcopy.c')
-rw-r--r--src/hardcopy.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/hardcopy.c b/src/hardcopy.c
index 744a2a2f19..0747dc9d3e 100644
--- a/src/hardcopy.c
+++ b/src/hardcopy.c
@@ -1943,6 +1943,7 @@ prt_open_resource(resource)
fclose(fd_resource);
return FALSE;
}
+ fclose(fd_resource);
prt_resfile.line_end = -1;
prt_resfile.line_start = 0;
@@ -1956,7 +1957,6 @@ prt_open_resource(resource)
{
EMSG2(_("E618: file \"%s\" is not a PostScript resource file"),
resource->filename);
- fclose(fd_resource);
return FALSE;
}
@@ -1974,7 +1974,6 @@ prt_open_resource(resource)
{
EMSG2(_("E619: file \"%s\" is not a supported PostScript resource file"),
resource->filename);
- fclose(fd_resource);
return FALSE;
}
offset += (int)STRLEN(PRT_RESOURCE_RESOURCE);
@@ -1993,7 +1992,6 @@ prt_open_resource(resource)
{
EMSG2(_("E619: file \"%s\" is not a supported PostScript resource file"),
resource->filename);
- fclose(fd_resource);
return FALSE;
}
@@ -2036,12 +2034,9 @@ prt_open_resource(resource)
{
EMSG2(_("E619: file \"%s\" is not a supported PostScript resource file"),
resource->filename);
- fclose(fd_resource);
return FALSE;
}
- fclose(fd_resource);
-
return TRUE;
}