[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdeedu/marble/src/lib/geodata/scene
From: Torsten Rahn <tackat () kde ! org>
Date: 2008-03-11 14:53:04
Message-ID: 1205247184.453612.22584.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 784505 by rahn:
- memory leak ...
M +3 -2 GeoSceneSettings.cpp
M +1 -1 GeoSceneSettings.h
--- trunk/KDE/kdeedu/marble/src/lib/geodata/scene/GeoSceneSettings.cpp #784504:784505
@@ -40,10 +40,11 @@
m_properties.insert( name, property );
}
-GeoSceneProperty* GeoSceneSettings::property( const QString& name ) const
+GeoSceneProperty* GeoSceneSettings::property( const QString& name )
{
GeoSceneProperty* property = m_properties.value( name );
- if ( property == 0 ) property = new GeoSceneProperty;
+ if ( !property )
+ addProperty( name , new GeoSceneProperty );
property->setName(name);
return property;
--- trunk/KDE/kdeedu/marble/src/lib/geodata/scene/GeoSceneSettings.h #784504:784505
@@ -41,7 +41,7 @@
* @param property the new property
*/
void addProperty( const QString& name, GeoSceneProperty* property );
- GeoSceneProperty* property( const QString& name ) const;
+ GeoSceneProperty* property( const QString& name );
protected:
/// The hash table holding all the properties in the settings.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic