summaryrefslogtreecommitdiff
path: root/ppdc
diff options
context:
space:
mode:
authorMichael R Sweet <michael.r.sweet@gmail.com>2018-08-21 10:01:44 -0400
committerMichael R Sweet <michael.r.sweet@gmail.com>2018-08-21 10:01:44 -0400
commit3416fe952b3852bb7076d64b54048cc2fac1f80c (patch)
treeb0118cc382b0e0ceb21729d8e519e5b7d002cf1c /ppdc
parent5c463d3fe0cdac4ed29c7124daf04e1fdcfe7186 (diff)
downloadcups-3416fe952b3852bb7076d64b54048cc2fac1f80c.tar.gz
Fix memory leaks found by Coverity (Issue #5375)
Diffstat (limited to 'ppdc')
-rw-r--r--ppdc/ppdc-source.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/ppdc/ppdc-source.cxx b/ppdc/ppdc-source.cxx
index be24cebae..4e8cba7bb 100644
--- a/ppdc/ppdc-source.cxx
+++ b/ppdc/ppdc-source.cxx
@@ -1,10 +1,11 @@
//
// Source class for the CUPS PPD Compiler.
//
-// Copyright 2007-2014 by Apple Inc.
+// Copyright 2007-2018 by Apple Inc.
// Copyright 2002-2007 by Easy Software Products.
//
-// Licensed under Apache License v2.0. See the file "LICENSE" for more information.
+// Licensed under Apache License v2.0. See the file "LICENSE" for more
+// information.
//
//
@@ -2665,6 +2666,7 @@ ppdcSource::scan_file(ppdcFile *fp, // I - File to read
// Add it to the current option...
if (!o)
{
+ c->release();
_cupsLangPrintf(stderr,
_("ppdc: Choice found on line %d of %s with no "
"Option."), fp->line, fp->filename);