Author: Matti Picus <matti.pi...@gmail.com>
Branch: unicode-utf8
Changeset: r95565:1687366068c8
Date: 2019-01-01 22:20 +0200
http://bitbucket.org/pypy/pypy/changeset/1687366068c8/

Log:    blindly try to fix win32 failure

diff --git a/pypy/module/_cffi_backend/misc.py 
b/pypy/module/_cffi_backend/misc.py
--- a/pypy/module/_cffi_backend/misc.py
+++ b/pypy/module/_cffi_backend/misc.py
@@ -398,8 +398,9 @@
 def dlopen_w(space, w_filename, flags):
     if WIN32 and space.isinstance_w(w_filename, space.w_unicode):
         fname = space.text_w(space.repr(w_filename))
-        unicode_name = space.unicode_w(w_filename)
-        with rffi.scoped_unicode2wcharp(unicode_name) as ll_libname:
+        utf8_name = space.utf8_w(w_filename)
+        uni_len = space.len_w(w_filename)
+        with rffi.scoped_utf82wcharp(utf8_name, uni_len) as ll_libname:
             try:
                 handle = dlopenU(ll_libname, flags)
             except DLOpenError as e:
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to