Commit Graph

154 Commits

Author SHA1 Message Date
6bcc263b41 Ensure LAMMPS pointer is of type c_void_p
Fixes segfaults caused by API change. The API change in
lammps_open and lammps_open_no_mpi makes them return the LAMMPS pointer
via their return value. However due to how ctypes operates, even
if restype is specified to be c_void_p, the function returns an integer.

Without the proper type of the pointer, calling functions without arglists would default
to using 32bit integers to pass an argument, which cuts away parts of the 64bit pointer.
Subsequently, resolving the truncated pointer in the library causes segfaults.

This commit fixes the root cause. But it also highlights the need of specifying
the arglists of all library functions.
2020-08-28 14:21:03 -04:00
167f12a4a4 Add python test for extract_compute of peratom vector 2020-08-28 13:53:36 -04:00
d7e2be1c81 Start Python interface tests for numpy extensions 2020-08-27 17:47:49 -04:00
69cffb2d04 import test infrastructure for c, c++ and python library usage 2020-08-25 11:03:31 -04:00