#88 closed defect (fixed)

scandir does not do error cleanup

Reported by: jack Owned by: Jennifer Averett
Priority: lowest Milestone: 2
Component: fs Version: 4.5
Severity: normal Keywords:
Cc: bugs@…, joel.sherrill@… Blocked By:


It seems we found bugs in scandir.c(copied from
newlib-1.9.0) - if an error occured
there is no clean up activity is made on return (
dinamically allocated memory is not freed). Seems it is not
very important because sys call scandir is used very seldom
and only CONFORMING TO BSD 4.3. But if this call presents in
RTEMS the bugs should be fixed. Because scandir.c is just
copied from newlib there are two approaches: fix the bugs
locally in RTMES src tree or make patch to newlib.

RTEMS CVS and probably 4.5

Attachments (2)

scandir.c (5.1 KB) - added by jack on Dec 3, 2006 at 1:31:12 PM.
scandir.diff (2.6 KB) - added by jack on Dec 3, 2006 at 1:31:12 PM.

Download all attachments as: .zip

Change History (2)

comment:1 Changed on Nov 30, 2001 at 11:06:44 AM by Joel Sherrill

Status: assignedclosed

State-Changed-From-To: analyzed->closed
State-Changed-Why: Attached patch is now committed

Changed on Dec 3, 2006 at 1:31:12 PM by jack

Attachment: scandir.diff added


Note: See TracTickets for help on using tickets.