Skip to content

Commit

Permalink
Fix QGIS Crash on loading WFS/WMS/XYZ layer from GeoNode.
Browse files Browse the repository at this point in the history
  • Loading branch information
ismailsunni authored and nyalldawson committed Sep 12, 2017
1 parent 92a1550 commit 3d3ff70
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/providers/ows/qgsgeonodedataitems.cpp
Expand Up @@ -21,7 +21,7 @@
#include "qgsgeonodenewconnection.h"
#include "qgsgeonoderequest.h"

typedef QList<QgsDataItemProvider *> dataItemProviders_t();
typedef QList<QgsDataItemProvider *> *dataItemProviders_t();

QgsGeoNodeConnectionItem::QgsGeoNodeConnectionItem( QgsDataItem *parent, QString name, QString path, QgsGeoNodeConnection *conn )
: QgsDataCollectionItem( parent, name, path )
Expand Down Expand Up @@ -137,7 +137,8 @@ QVector<QgsDataItem *> QgsGeoNodeServiceItem::createChildren()
QString path = pathPrefix + mName;

QVector<QgsDataItem *> items;
Q_FOREACH ( QgsDataItemProvider *pr, dataItemProvidersFn() )
QList<QgsDataItemProvider *> *providerList = dataItemProvidersFn();
Q_FOREACH ( QgsDataItemProvider *pr, *providerList )
{
items = pr->name().startsWith( mServiceName ) ? pr->createDataItems( path, this ) : items;
if ( !items.isEmpty() )
Expand Down

0 comments on commit 3d3ff70

Please sign in to comment.