From df3d3b5ddc2f0f10ba764e235f6786114fd24aab Mon Sep 17 00:00:00 2001 From: Denny Sheirer Date: Thu, 13 Apr 2023 04:31:46 -0400 Subject: [PATCH] #1519 Adds null checking to channel results array to detect null on tuner shutdown. (#1520) Co-authored-by: Dennis Sheirer --- .../channelizer/ComplexPolyphaseChannelizerM2.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/main/java/io/github/dsheirer/dsp/filter/channelizer/ComplexPolyphaseChannelizerM2.java b/src/main/java/io/github/dsheirer/dsp/filter/channelizer/ComplexPolyphaseChannelizerM2.java index 81552abf..fdf2e700 100644 --- a/src/main/java/io/github/dsheirer/dsp/filter/channelizer/ComplexPolyphaseChannelizerM2.java +++ b/src/main/java/io/github/dsheirer/dsp/filter/channelizer/ComplexPolyphaseChannelizerM2.java @@ -421,9 +421,12 @@ public class ComplexPolyphaseChannelizerM2 extends AbstractComplexPolyphaseChann for(float[] channelResults: list) { - //Rotate each of the channels to the correct phase using the IFFT - mFFT.complexInverse(channelResults, true); - processedChannelResults.add(channelResults); + if(channelResults != null) + { + //Rotate each of the channels to the correct phase using the IFFT + mFFT.complexInverse(channelResults, true); + processedChannelResults.add(channelResults); + } } dispatch(processedChannelResults);