Memory leak in subst_user
-------------------------

                 Key: SER-374
                 URL: http://tracker.iptel.org/browse/SER-374
             Project: SER
          Issue Type: Bug
          Components: Unspecified
    Affects Versions: 0.9.6
         Environment: Tested on Solaris 10 running on SUN T2000
            Priority: Critical


subst_user in modules/textops/textops.c uses subst_str() to perform a regular 
expression substitution. Subst_str returns a pkg malloc'd result in the form of 
a str. The contents of the str also have another pkg malloc'd fragment 
containing the bytes of the string (str.s).
subst_user correctly pkg_free's the result str but doesn't pkg_free the 
result->s.

Need to include:
if (result->s) pkg_free(result->s);

before line 434:
pkg_free(result);

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://tracker.iptel.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        
_______________________________________________
Serdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/serdev

Reply via email to