History

src/src_*.c : Validate internally stashed src_ratio value.

Erik de Castro Lopo committed 14 years ago

Commit f4e2bc31 parent a25ac784 files · +28 −2Browse files

Showing the changes to src/src_linear.c (1 of 4 files). Show all

Unified · Split

src/src_linear.c+5−1
@@ -1,5 +1,5 @@
11 /*
2−** Copyright (C) 2002-2011 Erik de Castro Lopo <erikd@mega-nerd.com>
2+** Copyright (C) 2002-2012 Erik de Castro Lopo <erikd@mega-nerd.com>
33 **
44 ** This program is free software; you can redistribute it and/or modify
55 ** it under the terms of the GNU General Public License as published by
@@ -78,6 +78,10 @@ linear_vari_process (SRC_PRIVATE *psrc, SRC_DATA *data) · 72 unmodified lines
7878 priv->in_used = priv->out_gen = 0 ;
7979
8080 src_ratio = psrc->last_ratio ;
81+
82+ if (is_bad_src_ratio (src_ratio))
83+ return SRC_ERR_BAD_INTERNAL_STATE ;
84+
8185 input_index = psrc->last_position ;
8286
8387 /* Calculate samples before first sample in input array. */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t