From: | "Justin Lecher (jlec)" <jlec@g.o> |
---|---|
To: | gentoo-commits@l.g.o |
Subject: | [gentoo-commits] gentoo-x86 commit in sci-libs/libsvm/files: 2.90-python3.patch |
Date: | Thu, 11 Feb 2010 18:53:58 |
Message-Id: | E1NfeAm-0003ze-OB@stork.gentoo.org |
1 | jlec 10/02/11 18:53:56 |
2 | |
3 | Added: 2.90-python3.patch |
4 | Log: |
5 | Added python3 support, thanks for help Kacper Kowalik |
6 | (Portage version: 2.2_rc62/cvs/Linux x86_64) |
7 | |
8 | Revision Changes Path |
9 | 1.1 sci-libs/libsvm/files/2.90-python3.patch |
10 | |
11 | file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/libsvm/files/2.90-python3.patch?rev=1.1&view=markup |
12 | plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/libsvm/files/2.90-python3.patch?rev=1.1&content-type=text/plain |
13 | |
14 | Index: 2.90-python3.patch |
15 | =================================================================== |
16 | diff --git a/python/svmc_wrap.c b/python/svmc_wrap.c |
17 | index 22ea45d..c4282b1 100644 |
18 | --- a/python/svmc_wrap.c |
19 | +++ b/python/svmc_wrap.c |
20 | @@ -758,7 +758,7 @@ SWIG_Python_str_AsChar(PyObject *str) |
21 | #if PY_VERSION_HEX >= 0x03000000 |
22 | char *cstr; |
23 | char *newstr; |
24 | - int len; |
25 | + Py_ssize_t len; |
26 | str = PyUnicode_AsUTF8String(str); |
27 | PyBytes_AsStringAndSize(str, &cstr, &len); |
28 | newstr = (char *) malloc(len+1); |