From 7a89cfe702d96c811ee3b9f56c921d9275978993 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 23 Oct 2012 08:20:01 +0530 Subject: [PATCH] ... --- src/calibre/libwand.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/calibre/libwand.py b/src/calibre/libwand.py index 97dc39ff6d..e232d3ab7e 100644 --- a/src/calibre/libwand.py +++ b/src/calibre/libwand.py @@ -23,16 +23,16 @@ class Severity(ctypes.c_long): pass class String(ctypes.c_char_p): - + def __del__(self): _libwand.MagickRelinquishMemory(self) - + def __str__(self): return self.value if _libwand is not None: _libwand.MagickGetException.argtypes = [ctypes.c_void_p, ctypes.POINTER(Severity)] - _libwand.MagickGetException.restype = String + _libwand.MagickGetException.restype = String def get_exception(wand): severity = Severity() @@ -52,4 +52,4 @@ def convert(source, dest): if not _libwand.MagickWriteImage(wand, dest): raise WandException('Cannot write image to file %s: %s'%(source, get_exception(wand))) _libwand.DestroyMagickWand(wand) - _libwand.MagickWandTerminus() \ No newline at end of file + _libwand.MagickWandTerminus()