Changeset 5299 for trunk


Ignore:
Timestamp:
10/20/04 17:36:04 (20 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r5298 r5299  
    4343   * mhist/MHCamera.cc:
    4444     - fixed returning GetBinError for kProfile mode switched on
     45
     46   * mbase/MDirIter.cc:
     47     - fixed a bug in the Sort function: AddDirectory was incorrectly used
    4548
    4649
  • trunk/MagicSoft/Mars/mbase/MDirIter.cc

    r5144 r5299  
    377377    TObject *o=0;
    378378    while ((o=NextN()))
    379            AddDirectory(o->GetName());
    380 }
     379    {
     380        TString dir  = o->GetName();
     381        TString name = o->GetName();
     382
     383        const Int_t last = dir.Last('/');
     384        if (last<0)
     385            continue;
     386
     387        dir.Remove(last);
     388        name.Remove(0, last+1);
     389
     390        AddDirectory(dir, name);
     391    }
     392}
Note: See TracChangeset for help on using the changeset viewer.