Skip to content

Commit

Permalink
Thumbnails: Declare more interface types
Browse files Browse the repository at this point in the history
Seems to address a segfault indicated in #1433, but there are still crashes
lurking.
  • Loading branch information
sampsyo committed Nov 20, 2015
1 parent fd2cacb commit 530b421
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions beetsplug/thumbnails.py
Expand Up @@ -234,8 +234,13 @@ def __init__(self):
self.available = bool(self.libgio)
if self.available:
self.libgio.g_type_init() # for glib < 2.36

self.libgio.g_file_get_uri.argtypes = [ctypes.c_char_p]
self.libgio.g_file_new_for_path.restype = ctypes.c_void_p

self.libgio.g_file_get_uri.argtypes = [ctypes.c_void_p]
self.libgio.g_file_get_uri.restype = ctypes.c_char_p

self.libgio.g_object_unref.argtypes = [ctypes.c_void_p]

def get_library(self):
Expand Down

0 comments on commit 530b421

Please sign in to comment.