Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
python-pyalsa
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Debian Python Team
packages
python-pyalsa
Commits
cd02a79d
Commit
cd02a79d
authored
3 years ago
by
Stefano Rivera
Browse files
Options
Downloads
Patches
Plain Diff
Patch: Python 3.10 support (fix PyTuple_SET_ITEM() usage). (Closes: #999385)
parent
6f51365d
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
debian/changelog
+4
-0
4 additions, 0 deletions
debian/changelog
debian/patches/python-3.10.patch
+48
-0
48 additions, 0 deletions
debian/patches/python-3.10.patch
debian/patches/series
+1
-0
1 addition, 0 deletions
debian/patches/series
with
53 additions
and
0 deletions
debian/changelog
+
4
−
0
View file @
cd02a79d
...
...
@@ -10,6 +10,10 @@ python-pyalsa (1.1.6-3) UNRELEASED; urgency=medium
* Bump debhelper from old 11 to 12.
* Bump debhelper from old 12 to 13.
[ Stefano Rivera ]
* Patch: Python 3.10 support (fix PyTuple_SET_ITEM() usage).
(Closes: #999385)
-- Ondřej Nový <onovy@debian.org> Thu, 24 Sep 2020 08:52:33 +0200
python-pyalsa (1.1.6-2) unstable; urgency=medium
...
...
This diff is collapsed.
Click to expand it.
debian/patches/python-3.10.patch
0 → 100644
+
48
−
0
View file @
cd02a79d
From: Jaroslav Kysela <perex@perex.cz>
Date: Fri, 19 Nov 2021 22:33:11 -0400
Subject: Fix PyTuple_SET_ITEM() usage - no return value
As noted in bpo-30459 (link bellow) the PyTuple_SET_ITEM() macro
has not a return value. Let's make code compatible with python 3.10.
Link: https://bugs.python.org/issue30459
BugLink: #2
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Origin: upstream, https://github.com/alsa-project/alsa-python/commit/5ea2f8709b4d091700750661231f8a3ddce0fc7c
Bug-Debian: https://bugs.debian.org/999385
---
pyalsa/alsahcontrol.c | 4 ++--
pyalsa/alsamixer.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/pyalsa/alsahcontrol.c b/pyalsa/alsahcontrol.c
index ebee1b7..7c9321f 100644
--- a/pyalsa/alsahcontrol.c
+++ b/pyalsa/alsahcontrol.c
@@ -1543,8 +1543,8 @@
static int element_callback(snd_hctl_elem_t *elem, unsigned int mask)
t = PyTuple_New(2);
if (t) {
- if (PyTuple_SET_ITEM(t, 0, (PyObject *)pyhelem))
- Py_INCREF(pyhelem);
+ PyTuple_SET_ITEM(t, 0, (PyObject *)pyhelem);
+ Py_INCREF(pyhelem);
PyTuple_SET_ITEM(t, 1, PyInt_FromLong(mask));
r = PyObject_CallObject(o, t);
Py_DECREF(t);
diff --git a/pyalsa/alsamixer.c b/pyalsa/alsamixer.c
index 39d7387..91fe198 100644
--- a/pyalsa/alsamixer.c
+++ b/pyalsa/alsamixer.c
@@ -1348,8 +1348,8 @@
static int element_callback(snd_mixer_elem_t *elem, unsigned int mask)
t = PyTuple_New(2);
if (t) {
- if (PyTuple_SET_ITEM(t, 0, (PyObject *)pyelem))
- Py_INCREF(pyelem);
+ PyTuple_SET_ITEM(t, 0, (PyObject *)pyelem);
+ Py_INCREF(pyelem);
PyTuple_SET_ITEM(t, 1, PyInt_FromLong(mask));
r = PyObject_CallObject(o, t);
Py_DECREF(t);
This diff is collapsed.
Click to expand it.
debian/patches/series
0 → 100644
+
1
−
0
View file @
cd02a79d
python-3.10.patch
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment