[Bug 1967] Potential memory leak in ssh [detected by melton]

bugzilla-daemon at bugzilla.mindrot.org bugzilla-daemon at bugzilla.mindrot.org
Wed Jan 4 19:40:43 EST 2012


--- Comment #5 from Zhenbo Xu <zhenbo1987 at gmail.com> 2012-01-04 19:40:43 EST ---
(In reply to comment #4)
> http://lcs.ios.ac.cn/~xuzb/bugsfound/memleak/openssh-5.9p1/realbugs/report-u6oVoX.html#EndPath
> This report means that the heap object allocated to fwd.connect_host 
> by function "parse_forward" is not freed at the end of the function
> since fwd is a local variable.

Is this report a real bug? If so, shall we fix this bug?

> http://lcs.ios.ac.cn/~xuzb/bugsfound/memleak/openssh-5.9p1/realbugs/report-Fs8fvc.html#EndPath
> In this report, the loop below iterates two times. At the first
> iteration, a heap object is allocated to options->user at "charptr =
> &options->user; ... *charptr = xstrdup(arg);", which is leaked at the
> second iteration if options->user is reassigned.
> while (fgets(line, sizeof(line), f)) {
>   linenum++;
>   if (process_config_line(options, host, line, filename, linenum,
> &active) != 0)
>     bad_options++;
> }

This report may be a false positive as options->user will never be

> Here is a list of some bugs, most of which are confirmed as false
> alarms by myself. It may contain some potential bugs or be helpful with
> you, although most of these are useless or can be eliminated by
> improving our tool.
> http://lcs.ios.ac.cn/~xuzb/bugsfound/memleak/openssh-5.9p1/falsealarms/index.html

Configure bugmail: https://bugzilla.mindrot.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
You are watching someone on the CC list of the bug.

More information about the openssh-bugs mailing list