Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5211 in orxonox.OLD for trunk/src/util


Ignore:
Timestamp:
Sep 21, 2005, 2:21:41 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: valgrind mem-leak-recovered

Location:
trunk/src/util
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/util/loading/load_param.cc

    r5141 r5211  
    133133  this->types = NULL;
    134134  this->description = NULL;
     135  this->defaultValues = NULL;
    135136  this->paramName = new char[strlen(paramName)+1];
    136137  strcpy(this->paramName, paramName);
    137   this->defaultValues = NULL;
    138138}
    139139
     
    158158  }
    159159
    160   delete []this->types;
    161   delete []this->defaultValues;
    162   delete []this->paramName;
    163   delete []this->description;
     160  delete[] this->types;
     161  delete[] this->defaultValues;
     162  delete[] this->paramName;
     163  delete[] this->description;
    164164}
    165165
  • trunk/src/util/resource_manager.cc

    r5208 r5211  
    8181    }
    8282  delete tmpIt;
    83 
    8483  delete this->imageDirs;
     84
     85  delete[] this->dataDir;
    8586
    8687  ResourceManager::singletonRef = NULL;
     
    356357                      PRINTF(4)("Image %s resides to %s\n", fileName, imgName);
    357358                      tmpResource->pointer = new Texture(imgName);
    358                       delete []imgName;
     359                      delete[] imgName;
    359360                      break;
    360361                    }
    361                   delete []imgName;
     362                  delete[] imgName;
    362363                  tmpDir = iterator->nextElement();
    363364                }
     
    375376      if (tmpResource->pointer)
    376377        this->resourceList->add(tmpResource);
    377       delete []fullName;
     378      delete[] fullName;
    378379    }
    379380  if (tmpResource->pointer)
     
    631632    }
    632633  else
     634  {
     635    delete[] tmpDirName;
    633636    return false;
     637  }
    634638}
    635639
Note: See TracChangeset for help on using the changeset viewer.