Commit e38998cc authored by Guillaume Seguin's avatar Guillaume Seguin

Workaround OSX-specific issue (see #619)

parent bd99abd9
......@@ -37,7 +37,10 @@ def SetUpIOFramework():
def StringToCFString(string):
# we'll need to convert our strings before use
encoding = CoreFoundation.kCFStringEncodingASCII
try:
encoding = CoreFoundation.kCFStringEncodingASCII
except AttributeError:
encoding = 0x600
cfstring = CoreFoundation.CFStringCreateWithCString(None, string, encoding)
return objc.pyobjc_id(cfstring.nsstring())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment