/tags/rel-1-3-29/SWIG/Examples/test-suite/python/li_cmalloc_runme.py
# · Python · 14 lines · 11 code · 3 blank · 0 comment · 2 complexity · 6b3b32a47b72d7ce96b0320b336a22d1 MD5 · raw file
- from li_cmalloc import *
- p = malloc_int()
- free_int(p)
- ok = 0
- try:
- p = calloc_int(-1)
- free_int(p)
- except:
- ok = 1
- if ok != 1:
- raise RuntimeError