I get the libscarab working under 64Bit Mac. Pass the testsuit tests.
While I am trying to work with the python wrapper, I have problem with all de/serialization methods. Take this simple method as an example.
def test_mpz_serialization(self):
print('begin')
mpz = make_c_mpz_t()
print('made mpz')
stringified = serialize_c_mpz_t(mpz)
print("after stringified")
assert_equals(stringified, '0')
which trigger this method
def serialize_c_mpz_t(mpz):
"""
Serialize mpz_t
:type mpz: c_mpz_t
:rtype : str
"""
c_str = lib_gmp.__gmpz_get_str(None, base, mpz)
if c_str == None:
print "none"
else:
print "has some thing"
result = string_at(c_str)
#.decode('ascii')
#libc.free(c_str)
return None
The nosetests failed at result = string_at(c_str). Would this be memory access problem? invalid memory? I confirm that same codes run fine under ubuntu build, using virtual machine in the same Mac.
Any idea?
I get the libscarab working under 64Bit Mac. Pass the testsuit tests.
While I am trying to work with the python wrapper, I have problem with all de/serialization methods. Take this simple method as an example.
which trigger this method
def serialize_c_mpz_t(mpz):
"""
Serialize mpz_t
The nosetests failed at result = string_at(c_str). Would this be memory access problem? invalid memory? I confirm that same codes run fine under ubuntu build, using virtual machine in the same Mac.
Any idea?