Skip to content
This repository was archived by the owner on May 18, 2019. It is now read-only.

Commit ee7aaab

Browse files
adeas31OpenModelica-Hudson
authored andcommitted
ticket:5030 Fix the broken profiling for OMEdit
Belonging to [master]: - #3076
1 parent 5daaf9b commit ee7aaab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

SimulationRuntime/c/simulation/modelinfo.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ static void printPlotCommand(FILE *plt, const char *plotFormat, const char *titl
195195
}
196196
fprintf(plt, "set xlabel \"Global step number\"\n");
197197
fprintf(plt, "set ylabel \"Execution count\"\n");
198-
fprintf(plt, "set output \"%s_prof.%s%d_count.%s\"\n", prefix, idPrefix, id, plotFormat);
198+
fprintf(plt, "set output \"%s%s_prof.%s%d_count.%s\"\n", outputPath, prefix, idPrefix, id, plotFormat);
199199
fprintf(plt, formatCount, outputPath, prefix, 1+numFnsAndBlocks, 2+i, 2);
200200
}
201201
}
@@ -491,7 +491,7 @@ int printModelInfo(DATA *data, threadData_t *threadData, const char *outputPath,
491491
const char *omhome = data->simulationInfo->OPENMODELICAHOME;
492492
char *buf = NULL;
493493
int genHtmlRes;
494-
buf = (char*)malloc(230 + 2*strlen(plotfile) + 2*(omhome ? strlen(omhome) : 0));
494+
buf = (char*)malloc(230 + 2*strlen(plotfile) + 2*strlen(outputPath) + 2*(omhome ? strlen(omhome) : 0));
495495
assert(buf);
496496
#if defined(__MINGW32__) || defined(_MSC_VER) || defined(NO_PIPE)
497497
if(omhome) {

0 commit comments

Comments
 (0)