make VALUELENGTH constant consistent.
This commit is contained in:
@ -40,8 +40,6 @@ using namespace LAMMPS_NS;
|
||||
|
||||
enum{NONE,INT,DOUBLE,STRING,PTR};
|
||||
|
||||
#define VALUELENGTH 64 // also in variable.cpp
|
||||
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
@ -369,7 +367,7 @@ void PythonImpl::invoke_function(int ifunc, char *result)
|
||||
const char *pystr = PY_STRING_AS_STRING(pValue);
|
||||
if (pfuncs[ifunc].longstr)
|
||||
strncpy(pfuncs[ifunc].longstr,pystr,pfuncs[ifunc].length_longstr);
|
||||
else strncpy(result,pystr,VALUELENGTH-1);
|
||||
else strncpy(result,pystr,Variable::VALUELENGTH-1);
|
||||
}
|
||||
}
|
||||
Py_CLEAR(pValue);
|
||||
|
||||
@ -49,7 +49,6 @@ using namespace MathConst;
|
||||
#define MAXLEVEL 4
|
||||
#define MAXLINE 256
|
||||
#define CHUNK 1024
|
||||
#define VALUELENGTH 64 // also in python.cpp
|
||||
#define MAXFUNCARG 6
|
||||
|
||||
#define MYROUND(a) (( a-floor(a) ) >= .5) ? ceil(a) : floor(a)
|
||||
|
||||
@ -72,6 +72,7 @@ class Variable : protected Pointers {
|
||||
PYTHON,
|
||||
INTERNAL
|
||||
};
|
||||
static constexpr int VALUELENGTH = 64;
|
||||
|
||||
private:
|
||||
int me;
|
||||
|
||||
Reference in New Issue
Block a user