Bug 24635

Summary: File Descriptor leaks in libxaw-1.0.7
Product: xorg Reporter: Eric Sesterhenn <eric.sesterhenn>
Component: Lib/XawAssignee: Xorg Project Team <xorg-team>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
fix file descriptor leaks none

Description Eric Sesterhenn 2009-10-20 01:21:46 UTC
Created attachment 30581 [details] [review]
fix file descriptor leaks

hi,

cppcheck reported two file descriptor leaks in libxaw

[libXaw-1.0.7/src/AsciiSrc.c:1297]: (error) Resource leak: fd
[libXaw-1.0.7/src/AsciiSrc.c:1353]: (error) Resource leak: fd

Attached patch fixes both cases.

Regards, Eric
Comment 1 Alan Coopersmith 2009-10-20 08:21:26 UTC
Applied, with one small change to allow it to actually compile:
-       close(fd)
+       close(fd);

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.