Skip to content

Commit

Permalink
Fixing element recorder parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
mhscott committed Jul 4, 2021
1 parent 8b38c01 commit 2712a25
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions SRC/recorder/ElementRecorder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -249,13 +249,14 @@ OPS_ElementRecorder()
nargrem = 1 + OPS_GetNumRemainingInputArgs();
data = new const char *[nargrem];
data[0] = option;
argv = new char*[nargrem];
//argv = new char*[nargrem];
char buffer[128];
for (int i = 1; i < nargrem; i++) {
argv[i] = new char[128];
data[i] = new char[128];

// Turn everything in to a string for setResponse
data[i] = OPS_GetStringFromAll(buffer, 128);
//data[i] = OPS_GetStringFromAll(buffer, 128);
OPS_GetStringFromAll((char*)data[i], 128);
}
}
}
Expand Down Expand Up @@ -287,11 +288,11 @@ OPS_ElementRecorder()
data, nargrem, echoTimeFlag, *domain, *theOutputStream,
dT, &dofs);

if (argv != 0) {
if (data != 0) {
for (int i=1; i<nargrem; ++i) {
delete [] argv[i];
delete [] data[i];
}
delete [] argv;
delete [] data;
}

return recorder;
Expand Down

0 comments on commit 2712a25

Please sign in to comment.