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.
41 lines
1.5 KiB
41 lines
1.5 KiB
From 37a7a2e60e310056553a39d1fd9a9fda6e565e7b Mon Sep 17 00:00:00 2001
|
|
From: Sandro <devel@penguinpee.nl>
|
|
Date: Fri, 19 Apr 2024 15:18:43 +0200
|
|
Subject: [PATCH] Python 3.13: Replace deprecated PyEval_CallObject()
|
|
|
|
The function has been deprecated since Python 3.9 and will be removed
|
|
from Python 3.13.
|
|
|
|
See: https://docs.python.org/3.13/whatsnew/3.13.html#id9
|
|
---
|
|
Wrapping/Python/gdcmswig.i | 2 +-
|
|
Wrapping/SWIGCommon/gdcmcommon.i | 2 +-
|
|
2 files changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/Wrapping/Python/gdcmswig.i b/Wrapping/Python/gdcmswig.i
|
|
index a2aa3760db..820178b599 100644
|
|
--- a/Wrapping/Python/gdcmswig.i
|
|
+++ b/Wrapping/Python/gdcmswig.i
|
|
@@ -623,7 +623,7 @@ static bool callback_helper(gdcm::DataSet const & ds1, gdcm::DataSet const & ds2
|
|
/* fail */
|
|
assert(0);
|
|
}
|
|
- result = PyEval_CallObject(func, arglist);
|
|
+ result = PyObject_CallObject(func, arglist);
|
|
Py_DECREF(arglist);
|
|
if (result && result != Py_None) {
|
|
PyErr_SetString(PyExc_TypeError,
|
|
diff --git a/Wrapping/SWIGCommon/gdcmcommon.i b/Wrapping/SWIGCommon/gdcmcommon.i
|
|
index 8794bce14c..449cf8c77a 100644
|
|
--- a/Wrapping/SWIGCommon/gdcmcommon.i
|
|
+++ b/Wrapping/SWIGCommon/gdcmcommon.i
|
|
@@ -631,7 +631,7 @@ static bool callback_helper(gdcm::DataSet const & ds1, gdcm::DataSet const & ds2
|
|
/* fail */
|
|
assert(0);
|
|
}
|
|
- result = PyEval_CallObject(func, arglist);
|
|
+ result = PyObject_CallObject(func, arglist);
|
|
Py_DECREF(arglist);
|
|
if (result && result != Py_None) {
|
|
PyErr_SetString(PyExc_TypeError,
|