[Bug 546098] New: dosemu-1.4.0.1-61.26: memory leak
http://bugzilla.novell.com/show_bug.cgi?id=546098 Summary: dosemu-1.4.0.1-61.26: memory leak Classification: openSUSE Product: openSUSE 11.2 Version: Factory Platform: All OS/Version: openSUSE 11.1 Status: NEW Severity: Minor Priority: P5 - None Component: Other AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: dcb314@hotmail.com QAContact: qa@suse.de Found By: --- I just had a look at factory package dosemu-1.4.0.1-61.26 source code file dosemu-1.4.0/src/base/misc/utilities.c function load_plugin I notice the following code char *fullname = malloc(strlen(dosemu_proc_self_exe) + strlen(plugin_name) + 20); void *handle; char *slash; strcpy(fullname, dosemu_proc_self_exe); slash = strrchr(fullname, '/'); if (slash == NULL) return NULL; So if the return is taken, then fullname is a memory leak. Suggest new code char *fullname = malloc(strlen(dosemu_proc_self_exe) + strlen(plugin_name) + 20); void *handle; char *slash; strcpy(fullname, dosemu_proc_self_exe); slash = strrchr(fullname, '/'); if (slash == NULL) { free( fullname); return NULL; } -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=546098
Andreas Jaeger
http://bugzilla.novell.com/show_bug.cgi?id=546098
Steffen Winterfeldt
http://bugzilla.novell.com/show_bug.cgi?id=546098
User marek.belisko@gmail.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=546098#c1
Marek Belisko
http://bugzilla.novell.com/show_bug.cgi?id=546098
User marek.belisko@gmail.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=546098#c2
--- Comment #2 from Marek Belisko
http://bugzilla.novell.com/show_bug.cgi?id=546098
User rguenther@novell.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=546098#c3
--- Comment #3 from Richard Guenther
http://bugzilla.novell.com/show_bug.cgi?id=546098
User prusnak@novell.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=546098#c4
Pavol Rusnak
participants (1)
-
bugzilla_noreply@novell.com