Skip to content

Commit

Permalink
- Fix to allow reading from result-files given an absolute path
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@9733 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
sjoelund committed Sep 2, 2011
1 parent dcdf16c commit e390e8e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Compiler/Script/CevalScript.mo
Expand Up @@ -1555,7 +1555,7 @@ algorithm
vars_1 = Util.listMap(cvars, ValuesUtil.printCodeVariableName);
pwd = System.pwd();
pd = System.pathDelimiter();
filename_1 = stringAppendList({pwd,pd,filename});
filename_1 = Util.if_(System.strncmp("/",filename,1)==0,filename,stringAppendList({pwd,pd,filename}));
value = ValuesUtil.readDataset(filename_1, vars_1, size);
then
(cache,value,st);
Expand All @@ -1569,7 +1569,7 @@ algorithm
equation
pwd = System.pwd();
pd = System.pathDelimiter();
filename_1 = stringAppendList({pwd,pd,filename});
filename_1 = Util.if_(System.strncmp("/",filename,1)==0,filename,stringAppendList({pwd,pd,filename}));
i = SimulationResults.readSimulationResultSize(filename_1);
then
(cache,Values.INTEGER(i),st);
Expand All @@ -1578,7 +1578,7 @@ algorithm
equation
pwd = System.pwd();
pd = System.pathDelimiter();
filename_1 = stringAppendList({pwd,pd,filename});
filename_1 = Util.if_(System.strncmp("/",filename,1)==0,filename,stringAppendList({pwd,pd,filename}));
args = SimulationResults.readVariables(filename_1);
vals = Util.listMap(args, ValuesUtil.makeString);
v = ValuesUtil.makeArray(vals);
Expand Down

0 comments on commit e390e8e

Please sign in to comment.