From 5fa6bc714e2b068358ccb40bdb7749381a1d74eb Mon Sep 17 00:00:00 2001 From: Eivind Kvedalen Date: Thu, 3 Dec 2015 21:36:21 +0100 Subject: [PATCH] App: Removed VariableExpression::setName(), and replace call by setPath(); it's use caused a crash (#2352). --- src/App/Expression.h | 2 -- src/Mod/Spreadsheet/App/PropertySheet.cpp | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/App/Expression.h b/src/App/Expression.h index 41d55ee158..c14cc310dd 100644 --- a/src/App/Expression.h +++ b/src/App/Expression.h @@ -349,8 +349,6 @@ public: void setPath(const ObjectIdentifier & path); - void setName(const std::string & name) { assert(0); } - void renameDocumentObject(const std::string & oldName, const std::string & newName); void renameDocument(const std::string &oldName, const std::string &newName); diff --git a/src/Mod/Spreadsheet/App/PropertySheet.cpp b/src/Mod/Spreadsheet/App/PropertySheet.cpp index 8d052bf8e5..c536a925bf 100644 --- a/src/Mod/Spreadsheet/App/PropertySheet.cpp +++ b/src/Mod/Spreadsheet/App/PropertySheet.cpp @@ -579,7 +579,7 @@ public: if (thisRow >= mRow || thisCol >= mCol) { thisRow += mRowCount; thisCol += mColCount; - varExpr->setName(columnName(thisCol) + rowName(thisRow)); + varExpr->setPath(ObjectIdentifier(varExpr->getOwner(), columnName(thisCol) + rowName(thisRow))); mChanged = true; } }