forked from lijiext/lammps
git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@9260 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
parent
37849c807e
commit
bad59e0fca
|
@ -210,6 +210,7 @@ void DumpCustom::init_style()
|
||||||
for (int i = 0; i < size_one; i++) {
|
for (int i = 0; i < size_one; i++) {
|
||||||
if (i == 0) ptr = strtok(format," \0");
|
if (i == 0) ptr = strtok(format," \0");
|
||||||
else ptr = strtok(NULL," \0");
|
else ptr = strtok(NULL," \0");
|
||||||
|
if (ptr == NULL) error->all(FLERR,"Dump_modify format string is too short");
|
||||||
delete [] vformat[i];
|
delete [] vformat[i];
|
||||||
vformat[i] = new char[strlen(ptr) + 2];
|
vformat[i] = new char[strlen(ptr) + 2];
|
||||||
strcpy(vformat[i],ptr);
|
strcpy(vformat[i],ptr);
|
||||||
|
|
Loading…
Reference in New Issue