From 7f625dc718670e5a5014e7ffa7cf653531b10791 Mon Sep 17 00:00:00 2001 From: Matthias Geier Date: Thu, 3 May 2018 11:11:13 +0200 Subject: play() etc.: force a copy of "mapping" Fixes #135. --- sounddevice.py | 1 + 1 file changed, 1 insertion(+) diff --git a/sounddevice.py b/sounddevice.py index c9c8117..54f521a 100644 --- a/sounddevice.py +++ b/sounddevice.py @@ -2446,6 +2446,7 @@ def _check_mapping(mapping, channels): if mapping is None: mapping = np.arange(channels) else: + mapping = np.array(mapping, copy=True) mapping = np.atleast_1d(mapping) if mapping.min() < 1: raise ValueError('channel numbers must not be < 1') -- cgit v1.2.3