From: jsimomaa Date: Mon, 11 Dec 2017 14:20:41 +0000 (+0200) Subject: Fix reference-bug in FMUSimulator simulateStep to update currentTime X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=refs%2Fheads%2Frelease%2F1.32.0.1;p=simantics%2Ffmil.git Fix reference-bug in FMUSimulator simulateStep to update currentTime refs #7649 Change-Id: Id1c98fd334a9a633e5ccf676f99bf19b7ba3af75 --- diff --git a/org.simantics.fmil.core/native/FMUSimulator/src/fmu_control.cpp b/org.simantics.fmil.core/native/FMUSimulator/src/fmu_control.cpp index 310e906..80c66ce 100644 --- a/org.simantics.fmil.core/native/FMUSimulator/src/fmu_control.cpp +++ b/org.simantics.fmil.core/native/FMUSimulator/src/fmu_control.cpp @@ -480,7 +480,7 @@ JNIEXPORT jint JNICALL Java_org_simantics_fmil_core_FMIL_instantiateSimulation_1 int returnValue; const char *error = ""; - FMI1 fmi = fmus[id]; + FMI1 &fmi = fmus[id]; if (fmi.version == 1) { returnValue = FMI1_CS_INSTANTIATE(fmi.fmu, "", &error); } else if (fmi.version == 2) { @@ -719,7 +719,7 @@ JNIEXPORT jint JNICALL Java_org_simantics_fmil_core_FMIL_simulateStep_1 int returnValue; const char *error = ""; - FMI1 fmi = fmus[id]; + FMI1 &fmi = fmus[id]; if (fmi.version == 1) { returnValue = FMI1_CS_STEP(fmi.fmu, fmi.currentTime, fmi.timeStep, &error); } else if (fmi.version == 2) { diff --git a/org.simantics.fmil.win32/libraries/Debug/FMUSimulator.dll b/org.simantics.fmil.win32/libraries/Debug/FMUSimulator.dll index 5e6f109..5682053 100644 Binary files a/org.simantics.fmil.win32/libraries/Debug/FMUSimulator.dll and b/org.simantics.fmil.win32/libraries/Debug/FMUSimulator.dll differ diff --git a/org.simantics.fmil.win32/libraries/FMUSimulator.dll b/org.simantics.fmil.win32/libraries/FMUSimulator.dll index 2907f2a..fd14ee6 100644 Binary files a/org.simantics.fmil.win32/libraries/FMUSimulator.dll and b/org.simantics.fmil.win32/libraries/FMUSimulator.dll differ diff --git a/org.simantics.fmil.win64/libraries/Debug/FMUSimulator.dll b/org.simantics.fmil.win64/libraries/Debug/FMUSimulator.dll index e142ebe..6ff8990 100644 Binary files a/org.simantics.fmil.win64/libraries/Debug/FMUSimulator.dll and b/org.simantics.fmil.win64/libraries/Debug/FMUSimulator.dll differ diff --git a/org.simantics.fmil.win64/libraries/FMUSimulator.dll b/org.simantics.fmil.win64/libraries/FMUSimulator.dll index d0922ca..53f0749 100644 Binary files a/org.simantics.fmil.win64/libraries/FMUSimulator.dll and b/org.simantics.fmil.win64/libraries/FMUSimulator.dll differ