(file) Return to Buffer.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/Buffer.cpp between version 1.4 and 1.5

version 1.4, 2006/01/30 16:16:46 version 1.5, 2006/03/15 23:13:58
Line 35 
Line 35 
  
 #include <cstring> #include <cstring>
 #include "Buffer.h" #include "Buffer.h"
   #include "Pegasus/Common/InternalException.h"
  
 PEGASUS_NAMESPACE_BEGIN PEGASUS_NAMESPACE_BEGIN
  
Line 61 
Line 62 
 static inline BufferRep* _allocate(size_t cap) static inline BufferRep* _allocate(size_t cap)
 { {
     BufferRep* rep = (BufferRep*)malloc(sizeof(BufferRep) + cap);     BufferRep* rep = (BufferRep*)malloc(sizeof(BufferRep) + cap);
       if (!rep)
       {
           throw PEGASUS_STD(bad_alloc)();
       }
     rep->cap = cap;     rep->cap = cap;
     return rep;     return rep;
 } }
Line 68 
Line 73 
 static inline BufferRep* _reallocate(BufferRep* rep, size_t cap) static inline BufferRep* _reallocate(BufferRep* rep, size_t cap)
 { {
     rep = (BufferRep*)realloc(rep, sizeof(BufferRep) + cap);     rep = (BufferRep*)realloc(rep, sizeof(BufferRep) + cap);
       if (!rep)
       {
           throw PEGASUS_STD(bad_alloc)();
       }
     rep->cap = cap;     rep->cap = cap;
     return rep;     return rep;
 } }


Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2