Skip to content

Commit

Permalink
Merge pull request eddie3#51 from stevensmedia/master
Browse files Browse the repository at this point in the history
Update conversion of Python strings to CF strings for Python 3
  • Loading branch information
Kalanyr authored Feb 3, 2022
2 parents 7ab1d02 + b5af1b7 commit 55e117c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gogrepoc.py
Original file line number Diff line number Diff line change
Expand Up @@ -2633,7 +2633,7 @@ def __init__(self):


def _CFSTR(self,py_string):
return CoreFoundation.CFStringCreateWithCString(None, py_string, CoreFoundation.kCFStringEncodingASCII)
return CoreFoundation.CFStringCreateWithCString(None, py_string.encode('utf-8'), CoreFoundation.kCFStringEncodingUTF8)

def raw_ptr(self,pyobjc_string):
return objc.pyobjc_id(pyobjc_string.nsstring())
Expand Down

0 comments on commit 55e117c

Please sign in to comment.