Changeset 21455

Show
Ignore:
Timestamp:
14.01.2010 19:34:40 (9 years ago)
Author:
ak19
Message:

Major bug fix after Dr Bainbridge debugged the server code which was causing the server to crash upon Enter Library: the line where it failed was simply where a local-scope text_t object was being naturally destructed. The real error was a memory corruption which the use of the new heapchk function helped to locate: collectset's inherited method configure() ought to have been specified as virtual, since it was declared virtual in the superclass configurable. A couple of destructors (in collectset and oaiservr's oaiconfig) have been made virtual as well since the superclass configurable has virtual methods which requires all related destructors to be virtual.

Location:
main/trunk/greenstone2/runtime-src/src
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/runtime-src/src/colservr/collectset.h

    r21453 r21455  
    3535#endif 
    3636 
    37   int                   noofservers; 
    3837  text_t                httpdomain; 
    3938  text_t                httpprefix; 
     
    4847  collectset(); 
    4948 
    50   ~collectset(); 
     49  virtual ~collectset(); 
    5150 
    5251  // initialise the collections 
     
    5453 
    5554  // configure all the servers as supplied 
    56   void configure (const text_t &key, const text_tarray &cfgline); 
     55  virtual void configure (const text_t &key, const text_tarray &cfgline); 
    5756 
    5857  // Add/remove collections 
  • main/trunk/greenstone2/runtime-src/src/oaiservr/oaiconfig.h

    r20629 r21455  
    2626  oaiconfig(); 
    2727  oaiconfig(text_t &gsdlhome, text_t &gsdlcollect); 
    28   ~oaiconfig(); 
     28  virtual ~oaiconfig(); 
    2929  virtual void  configure(const text_t &key, const text_tarray &cfgline); 
    3030  text_t        getCollectionConfig(const text_t &collection, const text_t &field);