You are viewing a plain text version of this content. The canonical link for it is here.
Posted to proton@qpid.apache.org by "Sahir Hoda (JIRA)" <ji...@apache.org> on 2014/10/14 18:52:34 UTC

[jira] [Created] (PROTON-712) Seg fault due to missing NULL return value check of getprotobyname

Sahir Hoda created PROTON-712:
---------------------------------

             Summary: Seg fault due to missing NULL return value check of getprotobyname
                 Key: PROTON-712
                 URL: https://issues.apache.org/jira/browse/PROTON-712
             Project: Qpid Proton
          Issue Type: Bug
          Components: proton-c
    Affects Versions: 0.7
            Reporter: Sahir Hoda


There are several places proton-c makes calls to getprotobyname and dereferences the return value without checking for NULL first. Documentation for getprotobyname indicates it can return NULL if there was an error. We have seen seg faults in testing where getprotobyname returned NULL.

Attached is a patch that adds some simple error checking to the getprotobyname call.



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