Browse Source

python: fix python3 problem

tags/v0.99.beta20
Alex Foulon 9 years ago
parent
commit
551ad91775
1 changed files with 4 additions and 1 deletions
  1. +4
    -1
      python/caca/canvas.py

+ 4
- 1
python/caca/canvas.py View File

@@ -47,7 +47,10 @@ class _Canvas(object):
_lib.caca_free_canvas.argtypes = [_Canvas]
_lib.caca_free_canvas.restype = ctypes.c_int

return _lib.caca_free_canvas(self)
if self is not None:
return _lib.caca_free_canvas(self)

return None

class Canvas(_Canvas):
""" Canvas object, methods are libcaca functions with canvas_t as


Loading…
Cancel
Save