Commits

Armin Rigo committed 170d742

Oups, fix.

Comments (0)

Files changed (1)

testing/test_ffi_backend.py

         s = ffi.new("struct s1 *")
         setattr(s, name, value)
         assert getattr(s, name) == value
-        raw1 = bytes(ffi.buffer(s))
+        raw1 = ffi.buffer(s)[:]
         if lib is not None:
             t = lib.try_with_value(fnames.index(name), value)
-            raw2 = bytes(ffi.buffer(t, len(raw1)))
+            raw2 = ffi.buffer(t, len(raw1))[:]
             assert raw1 == raw2
 
     def test_bitfield_basic(self):