[minicom-Bugs][315359] config.c:1874]: (error) Resource leak: fp

minicom-bugs at alioth.debian.org minicom-bugs at alioth.debian.org
Mon Apr 25 21:48:38 UTC 2016


minicom-Bugs item #315359 was changed at 2016-04-25 23:48 by Adam Lackorzynski
You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=100031&aid=315359&group_id=30018

>Status: Closed
Priority: 3
Submitted By: David Binderman (dcb314-guest)
>Assigned to: Adam Lackorzynski (al-guest)
Summary: config.c:1874]: (error) Resource leak: fp 
Category: None
Group: None
>Resolution: Fixed


Initial Comment:
Source code is

  if (   fread(vt_inmap, sizeof(vt_inmap), (size_t)1, fp) != 1
      || fread(vt_outmap, sizeof(vt_outmap), (size_t)1, fp) != 1)
    {
      werror(_("Cannot read conversion table %s"), pfix_home(buf));
      return 1;
    }

Suggest call fclose inside the if statement.


----------------------------------------------------------------------

>Comment By: Adam Lackorzynski (al-guest)
Date: 2016-04-25 23:48

Message:
Thanks!

----------------------------------------------------------------------

You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=100031&aid=315359&group_id=30018



More information about the minicom-devel mailing list