mirror of
https://github.com/tumic0/GPXSee.git
synced 2024-11-30 22:51:16 +01:00
Fixed crash when there is no graph in the data
This commit is contained in:
parent
9481e9b4e5
commit
0cd18c0927
@ -866,6 +866,8 @@ void GUI::loadData(const Data &data)
|
|||||||
paths = _mapView->loadData(data);
|
paths = _mapView->loadData(data);
|
||||||
|
|
||||||
GraphTab *gt = static_cast<GraphTab*>(_graphTabWidget->currentWidget());
|
GraphTab *gt = static_cast<GraphTab*>(_graphTabWidget->currentWidget());
|
||||||
|
if (!gt)
|
||||||
|
return;
|
||||||
int index = _graphTabWidget->currentIndex();
|
int index = _graphTabWidget->currentIndex();
|
||||||
|
|
||||||
for (int i = 0; i < paths.count(); i++) {
|
for (int i = 0; i < paths.count(); i++) {
|
||||||
|
Loading…
Reference in New Issue
Block a user