You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tre/SOURCES/tre-pep623.patch

22 lines
932 B

diff -up tre-c2f5d130c91b1696385a6ae0b5bcfd5214bcc9ca/python/tre-python.c.pep623 tre-c2f5d130c91b1696385a6ae0b5bcfd5214bcc9ca/python/tre-python.c
--- tre-c2f5d130c91b1696385a6ae0b5bcfd5214bcc9ca/python/tre-python.c.pep623 2023-09-28 18:14:11.839914165 +0200
+++ tre-c2f5d130c91b1696385a6ae0b5bcfd5214bcc9ca/python/tre-python.c 2023-09-28 18:26:22.469156493 +0200
@@ -365,7 +365,7 @@ PyTrePattern_search(TrePatternObject *se
if (PyUnicode_Check(pstring))
{
- Py_ssize_t len = PyUnicode_GetSize(pstring);
+ Py_ssize_t len = PyUnicode_GetLength(pstring);
wchar_t *buf = calloc(sizeof(wchar_t), len);
if(!buf)
{
@@ -502,7 +502,7 @@ PyTre_ncompile(PyObject *self, PyObject
if (upattern != NULL)
{
- Py_ssize_t len = PyUnicode_GetSize(upattern);
+ Py_ssize_t len = PyUnicode_GetLength(upattern);
wchar_t *buf = calloc(sizeof(wchar_t), len);
if(!buf)
{