bugCompact Disc Input and Control Library - Bugs: bug #18563, _fs_iso_stat_traverse looses...

 
 

bug #18563: _fs_iso_stat_traverse looses information about symlinks

Submitted by:  Antti Perälä <azperala>
Submitted on:  Wed 20 Dec 2006 09:03:32 AM UTC  
 
Category: APISeverity: 5 - Average
Item Group: libiso9660Status: Fixed
Privacy: PublicAssigned to: Rocky Bernstein <rocky>
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Wed 20 Dec 2006 09:28:40 AM UTC, comment #1:

Thanks for reporting this problem and providing a patch to fix it. Your patch has been applied and is currently in CVS sources (i.e. will be part of the next release whenever that is).

Again, thanks.

Rocky Bernstein <rocky>
Project AdministratorIn charge of this item.
Wed 20 Dec 2006 09:03:32 AM UTC, original submission:

Hi,

I was trying to fetch a file from iso image and since the file was a symlink to another I found a problem with iso9660 library. It seemed to corrupt the iso_rock_statbuf_s member psz_symlink.

iso9660_fs.c function _fs_iso_stat_traverse line 1054 I added these lines

p_stat->rr.psz_symlink = calloc(1, p_stat->rr.i_symlink_max);
memcpy(p_stat->rr.psz_symlink, _root->rr.psz_symlink, p_stat->rr.i_symlink_max);

because _root->rr.psz_symlink and p_stat->rr.psz_symlink point to the same memory location and _root->rr.psz_symlink is freed later at line 1118, of course now I have to remember to free p_stat->rr.psz_symlink before I free p_stat.

I attached my version of iso9660_fs.c

Antti Perälä <azperala>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #11567:  iso9660_fs.c added by azperala (40KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rocky (Posted a comment)
  • -unavailable- added by azperala (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 20 Dec 2006 09:28:40 AM UTCrockyStatusNone=>Fixed
      Assigned toNone=>rocky
      Open/ClosedOpen=>Closed
    Wed 20 Dec 2006 09:03:32 AM UTCazperalaAttached File-=>Added iso9660_fs.c, #11567

    Back to the top


    Powered by Savane 3.1-cleanup1