Ignore:
Timestamp:
Jul 16, 2015, 3:29:10 PM (9 years ago)
Author:
guerin
Message:

fat32: don't let a file replace itself in _fat_rename()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_fat32/fat32.c

    r620 r621  
    37733773    if ( code == 0 )       // new_path inode already exist
    37743774    {
     3775        if ( inode == old )  // the file will replace itself, do nothing
     3776        {
     3777            _spin_lock_release( &_fat.fat_lock );
     3778            return 0;
     3779        }
     3780
    37753781        to_remove        = inode;
    3776         new_parent       = inode->parent;   
     3782        new_parent       = inode->parent;
    37773783    }
    37783784    else if ( code == 1 )  // to_remove does not exist but parent exist
Note: See TracChangeset for help on using the changeset viewer.