Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#4042 closed defect (fixed)

OMEdit crash when saving model with conflicting variable names

Reported by: Pierre Haessig <pierre.haessig@…> Owned by: Adeel Asghar
Priority: high Milestone: 1.11.0
Component: OMEdit Version: v1.11.0
Keywords: Cc:

Description

I was mistakenly creating a Modelica code where there was a conflict between two identifiers (see attached file: parameter y00 and constant block y0). When saving the file in OMEdit, it crashes.

The bug is 100% reproducible on my machine (Debian testing, using the binary deb package, OMEdit version 1.11.0~dev-5-gfe7fc5f, Connected to OpenModelica 1.11.0~dev-155-gbf0142e, i.e. from the "jessie nightly" channel).

I'm attaching the file to reproduce the crash. Steps are:

1) Open the mo file in OMEdit
2) Rename the parameter y00 to "Y0" (so as to create the name conflict with block "y0")
3) Ctrl+S to save -> crash

Expected behavior: OMEdit shouldn't crash but instead report the name conflict.

Attachments (1)

Plant_O1.mo (2.0 KB ) - added by Pierre Haessig <pierre.haessig@…> 8 years ago.
example model file where a name conflict can be created ("y00" -> "y0")

Download all attachments as: .zip

Change History (3)

by Pierre Haessig <pierre.haessig@…>, 8 years ago

Attachment: Plant_O1.mo added

example model file where a name conflict can be created ("y00" -> "y0")

comment:1 by Adeel Asghar, 8 years ago

Resolution: fixed
Status: newclosed

Fixed in 1dd8804/OMEdit.

comment:2 by Adeel Asghar, 8 years ago

Milestone: Future1.11.0
Note: See TracTickets for help on using tickets.