kern/138379: Memory leak in output_listing() in file sys/dev/aic7xxx/aicasm/aicasm.c

Patroklos Argyroudis argp at census-labs.com
Mon Aug 31 10:10:03 UTC 2009


>Number:         138379
>Category:       kern
>Synopsis:       Memory leak in output_listing() in file sys/dev/aic7xxx/aicasm/aicasm.c
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Aug 31 10:10:02 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Patroklos Argyroudis
>Release:        8.0-CURRENT
>Organization:
census, inc
>Environment:
N/A
>Description:
There is a memory leak of pointer func_values which is allocated in line 554 but not freed.
>How-To-Repeat:
N/A
>Fix:
Patch attached.

Patch attached with submission follows:

--- ./sys/dev/aic7xxx/aicasm/aicasm.c.orig	2009-08-27 22:00:05.000000000 +0300
+++ ./sys/dev/aic7xxx/aicasm/aicasm.c	2009-08-27 22:48:58.000000000 +0300
@@ -643,6 +643,7 @@
 	while(fgets(buf, sizeof(buf), ifile) != NULL)
 		fprintf(listfile, "             %s", buf);
 
+	free(func_values);
 	fclose(ifile);
 }
 


>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list