Skip to content

Commit 949f894

Browse files
committed
use self.payload[:self.payload_len] for getting python string
This is more Cythonic way, documented here http://cython.readthedocs.io/en/latest/src/tutorial/strings.html#passing-byte-strings It compiles to __Pyx_PyBytes_FromStringAndSize( __pyx_v_self->payload + 0, __pyx_v_self->payload_len - 0) Which is the Cython macro wrapper which handles both Python 2 and Python3. Fixes oremanj#17
1 parent 9c74558 commit 949f894

File tree

2 files changed

+385
-426
lines changed

2 files changed

+385
-426
lines changed

0 commit comments

Comments
 (0)