mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-31 05:40:04 +00:00 
			
		
		
		
	dsp_interface: Move sink to the last in member list (#5844)
So that it is destructed first. Otherwise, the TimeStretcher will be destructed before the Sink, which might cause segfaults when the Sink tries to read data from the TimeStretcher afterwards.
This commit is contained in:
		
							parent
							
								
									4817b00843
								
							
						
					
					
						commit
						19617f7edb
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -108,12 +108,12 @@ private: | ||||||
|     void FlushResidualStretcherAudio(); |     void FlushResidualStretcherAudio(); | ||||||
|     void OutputCallback(s16* buffer, std::size_t num_frames); |     void OutputCallback(s16* buffer, std::size_t num_frames); | ||||||
| 
 | 
 | ||||||
|     std::unique_ptr<Sink> sink; |  | ||||||
|     std::atomic<bool> perform_time_stretching = false; |     std::atomic<bool> perform_time_stretching = false; | ||||||
|     std::atomic<bool> flushing_time_stretcher = false; |     std::atomic<bool> flushing_time_stretcher = false; | ||||||
|     Common::RingBuffer<s16, 0x2000, 2> fifo; |     Common::RingBuffer<s16, 0x2000, 2> fifo; | ||||||
|     std::array<s16, 2> last_frame{}; |     std::array<s16, 2> last_frame{}; | ||||||
|     TimeStretcher time_stretcher; |     TimeStretcher time_stretcher; | ||||||
|  |     std::unique_ptr<Sink> sink; | ||||||
| 
 | 
 | ||||||
|     template <class Archive> |     template <class Archive> | ||||||
|     void serialize(Archive& ar, const unsigned int) {} |     void serialize(Archive& ar, const unsigned int) {} | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue