Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3552 in orxonox.OLD for orxonox/trunk/src/lib/lang


Ignore:
Timestamp:
Mar 14, 2005, 11:58:59 PM (20 years ago)
Author:
bensch
Message:

orxonox/trunk: added init-function to PNode and chars now get copied and deleted instead of just the reference

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/lang/base_object.cc

    r3544 r3552  
    3737BaseObject::~BaseObject ()
    3838{
    39 
     39  delete []this->className;
    4040}
    4141
    4242void BaseObject::setClassName (char* className)
    4343{
    44   this->className = className;
     44  this->className = new char[strlen(className)+1];
     45  strcpy(this->className, className);
    4546}
    4647
Note: See TracChangeset for help on using the changeset viewer.