aboutsummaryrefslogtreecommitdiff
path: root/lib/UnrarXLib/savepos.cpp
blob: e46c4e666ce0287b21a6bc34f3fc826dac4f49b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#include "rar.hpp"

SaveFilePos::SaveFilePos(File &SaveFile)
{
  SaveFilePos::SaveFile=&SaveFile;
  SavePos=SaveFile.Tell();
  CloseCount=SaveFile.CloseCount;
}


SaveFilePos::~SaveFilePos()
{
  if (CloseCount==SaveFile->CloseCount)
    SaveFile->Seek(SavePos,SEEK_SET);
}