]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HLT/BASE/AliHLTMemoryFile.cxx
HLTcalo module
[u/mrichter/AliRoot.git] / HLT / BASE / AliHLTMemoryFile.cxx
index 9fd25ce60ca950452475b0d4a5f2929796218e1f..ba610a471c9c3f3aebb838a4a52c912d2e127cc2 100644 (file)
@@ -62,26 +62,6 @@ AliHLTMemoryFile::AliHLTMemoryFile(void* pBuffer, int iSize)
   //HLTDebug("created memory file %p, capacity %d, ROOT version %d", this, fBufferSize, fVersion);
 }
 
-AliHLTMemoryFile::AliHLTMemoryFile(const AliHLTMemoryFile&)
-  :
-  fpBuffer(NULL),
-  fBufferSize(0),
-  fPosition(0),
-  fSize(0),
-  fErrno(0),
-  fbClosed(0),
-  fHeaderSize(0),
-  fTrailerSize(0)
-{
-  // see header file for class documentation
-}
-
-AliHLTMemoryFile& AliHLTMemoryFile::operator=(const AliHLTMemoryFile&)
-{ 
-  // see header file for class documentation
-  return *this;
-}
-
 AliHLTMemoryFile::~AliHLTMemoryFile()
 {
   // see header file for function documentation
@@ -91,7 +71,12 @@ AliHLTMemoryFile::~AliHLTMemoryFile()
   }
 }
 
-int AliHLTMemoryFile::Close(int bFlush)
+void AliHLTMemoryFile::Close(const Option_t*)
+{
+  CloseMemoryFile();
+}
+
+int AliHLTMemoryFile::CloseMemoryFile(int bFlush)
 {
   fErrno=0;
   if (fbClosed) return 0;
@@ -109,7 +94,7 @@ int AliHLTMemoryFile::Close(int bFlush)
   return -fErrno;
 }
 
-Int_t    AliHLTMemoryFile::SysOpen(const char *pathname, Int_t flags, UInt_t mode)
+Int_t    AliHLTMemoryFile::SysOpen(const char* /*pathname*/, Int_t /*flags*/, UInt_t /*mode*/)
 {
   // see header file for function documentation
   if (fpBuffer==NULL || fSize==0) return 1;
@@ -119,14 +104,14 @@ Int_t    AliHLTMemoryFile::SysOpen(const char *pathname, Int_t flags, UInt_t mod
   return -1;
 }
 
-Int_t    AliHLTMemoryFile::SysClose(Int_t fd)
+Int_t    AliHLTMemoryFile::SysClose(Int_t /*fd*/)
 {
   // see header file for function documentation
   //HLTDebug("closing file %p size %d", this, fSize);
   return 0;
 }
 
-Int_t    AliHLTMemoryFile::SysRead(Int_t fd, void *buf, Int_t len)
+Int_t    AliHLTMemoryFile::SysRead(Int_t /*fd*/, void *buf, Int_t len)
 {
   // see header file for function documentation
   if (buf==NULL) return 0;
@@ -140,7 +125,7 @@ Int_t    AliHLTMemoryFile::SysRead(Int_t fd, void *buf, Int_t len)
   return read;
 }
 
-Int_t    AliHLTMemoryFile::SysWrite(Int_t fd, const void *buf, Int_t len)
+Int_t    AliHLTMemoryFile::SysWrite(Int_t /*fd*/, const void *buf, Int_t len)
 {
   // see header file for function documentation
   if (buf==NULL) return 0;
@@ -156,7 +141,7 @@ Int_t    AliHLTMemoryFile::SysWrite(Int_t fd, const void *buf, Int_t len)
   return -1;
 }
 
-Long64_t AliHLTMemoryFile::SysSeek(Int_t fd, Long64_t offset, Int_t whence)
+Long64_t AliHLTMemoryFile::SysSeek(Int_t /*fd*/, Long64_t offset, Int_t whence)
 {
   // see header file for function documentation
   //HLTDebug("seek %d from %d", offset, whence);
@@ -171,6 +156,7 @@ Long64_t AliHLTMemoryFile::SysSeek(Int_t fd, Long64_t offset, Int_t whence)
     break;
   case SEEK_END:
     position+=fSize;
+    break;
   default:
     position=-1;
     errno=EINVAL;
@@ -186,20 +172,20 @@ Long64_t AliHLTMemoryFile::SysSeek(Int_t fd, Long64_t offset, Int_t whence)
   return position;
 }
 
-Int_t    AliHLTMemoryFile::SysStat(Int_t fd, Long_t *id, Long64_t *size, Long_t *flags, Long_t *modtime)
+Int_t    AliHLTMemoryFile::SysStat(Int_t /*fd*/, Long_t */*id*/, Long64_t *size, Long_t */*flags*/, Long_t */*modtime*/)
 {
   // see header file for function documentation
   if (size) *size=fSize;
   return 0;
 }
 
-Int_t    AliHLTMemoryFile::SysSync(Int_t fd)
+Int_t    AliHLTMemoryFile::SysSync(Int_t /*fd*/)
 {
   // see header file for function documentation
   return 0;
 }
 
-int AliHLTMemoryFile::WriteHeader(const char* pHeader, int size)
+int AliHLTMemoryFile::WriteHeaderBuffer(const char* pHeader, int size)
 {
   // see header file for function documentation
   fErrno=0;
@@ -225,7 +211,7 @@ int AliHLTMemoryFile::WriteHeader(const char* pHeader, int size)
   return -fErrno;
 }
 
-// int AliHLTMemoryFile::WriteTrailer(const char* pTrailer, int size)
+// int AliHLTMemoryFile::WriteTrailerBuffer(const char* pTrailer, int size)
 // {
 //   // see header file for function documentation
 //   fErrno=0;