Skip to content
Permalink
Browse files

Fix server crashes when .qgs file replaced (refs #12411)

Cherry-picked from 232565d
  • Loading branch information
nyalldawson committed May 28, 2015
1 parent f5d4088 commit f659554452bf0cefcc9a6787a9e44bf6d9d5feaa
Showing with 6 additions and 3 deletions.
  1. +4 −1 src/server/qgsconfigcache.cpp
  2. +1 −1 src/server/qgsserverprojectparser.cpp
  3. +1 −1 src/server/qgsserverprojectparser.h
@@ -166,9 +166,12 @@ QDomDocument* QgsConfigCache::xmlDocument( const QString& filePath )

void QgsConfigCache::removeChangedEntry( const QString& path )
{
mXmlDocumentCache.remove( path );
mWMSConfigCache.remove( path );
mWFSConfigCache.remove( path );
mWCSConfigCache.remove( path );

//xml document must be removed last, as other config cache destructors may require it
mXmlDocumentCache.remove( path );

mFileSystemWatcher.removePath( path );
}
@@ -86,7 +86,7 @@ QgsServerProjectParser::QgsServerProjectParser()

QgsServerProjectParser::~QgsServerProjectParser()
{
delete mXMLDoc;

}

void QgsServerProjectParser::projectLayerMap( QMap<QString, QgsMapLayer*>& layerMap ) const
@@ -32,7 +32,7 @@ class QDomDocument;
class QgsServerProjectParser
{
public:
/**Takes ownership of the document*/

QgsServerProjectParser( QDomDocument* xmlDoc, const QString& filePath );
~QgsServerProjectParser();

0 comments on commit f659554

Please sign in to comment.
You can’t perform that action at this time.