Message232470
Your code is strange. It exchanges pointer between processes if I understand correctly:
class Berbagi(ctypes.Structure):
_fields_ = [('a', ctypes.c_wchar_p), ('b', ctypes.c_double) ]
nilai = multiprocessing.Array(Berbagi, [Berbagi() for x in range(9)] )
You must not do that. Instead, Berbagi.a must be an array of c_wchar characters with a fixed size. Try for example:
class Berbagi(ctypes.Structure):
_fields_ = [('a', ctypes.c_wchar * 10), ('b', ctypes.c_double) ]
Note: I'm not sure that ctypes is the most efficient module to serialize data, but maybe you have to use ctypes for a reason not explained in your issue.
The bug is in your code, not in Python. |
|
Date |
User |
Action |
Args |
2014-12-11 11:36:40 | vstinner | set | recipients:
+ vstinner, sys |
2014-12-11 11:36:40 | vstinner | set | messageid: <1418297800.45.0.552359995718.issue23022@psf.upfronthosting.co.za> |
2014-12-11 11:36:40 | vstinner | link | issue23022 messages |
2014-12-11 11:36:40 | vstinner | create | |
|