You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "David Binderman (JIRA)" <ji...@apache.org> on 2014/10/09 13:27:34 UTC

[jira] [Created] (DAEMON-324) [home.c:130]: (error) Resource leak: cfgf

David Binderman created DAEMON-324:
--------------------------------------

             Summary: [home.c:130]: (error) Resource leak: cfgf
                 Key: DAEMON-324
                 URL: https://issues.apache.org/jira/browse/DAEMON-324
             Project: Commons Daemon
          Issue Type: Bug
    Affects Versions: 1.0.15
            Reporter: David Binderman
            Priority: Minor


$ fgrep cfgf ../BUILD/commons-daemon-1.0.15-src/src/native/unix/native/home.c
    FILE *cfgf = fopen(data->cfgf, "r");
    if (cfgf == NULL) {
        log_debug("Can't open %s\n", data->cfgf);
    while ((ret = fgets(buf, 1024, cfgf)) != NULL) {
    char *cfgf = NULL;

Suggest add call to fclose.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)