History

Fix read and write return types: now st_size_t, like the size inputs.

To support this change, turn on lots more compiler warnings, and fix all the warnings generated.

rrt committed 19 years ago

Commit 4d743c41 parent ce1f8f393 files · +875 −1236Browse files

Showing the changes to src/echos.c (1 of 93 files). Show all

Unified · Split

src/echos.c+7−7
@@ -52,7 +52,7 @@ · 51 unmodified lines
5252
5353 static st_effect_t st_echos_effect;
5454
55−#define DELAY_BUFSIZ ( 50L * ST_MAXRATE )
55+#define DELAY_BUFSIZ ( 50 * ST_MAXRATE )
5656 #define MAX_ECHOS 7 /* 24 bit x ( 1 + MAX_ECHOS ) = */
5757 /* 24 bit x 8 = 32 bit !!! */
5858
@@ -72,7 +72,7 @@ typedef struct echosstuff { · 13 unmodified lines
7272 /*
7373 * Process options
7474 */
75−int st_echos_getopts(eff_t effp, int n, char **argv)
75+static int st_echos_getopts(eff_t effp, int n, char **argv)
7676 {
7777 echos_t echos = (echos_t) effp->priv;
7878 int i;
@@ -107,7 +107,7 @@ int st_echos_getopts(eff_t effp, int n, char **argv) · 28 unmodified lines
107107 /*
108108 * Prepare for processing.
109109 */
110−int st_echos_start(eff_t effp)
110+static int st_echos_start(eff_t effp)
111111 {
112112 echos_t echos = (echos_t) effp->priv;
113113 int i;
@@ -136,7 +136,7 @@ int st_echos_start(eff_t effp) · 22 unmodified lines
136136 st_fail("echos: delay must be positive!");
137137 return (ST_EOF);
138138 }
139− if ( echos->samples[i] > DELAY_BUFSIZ )
139+ if ( echos->samples[i] > (st_ssize_t)DELAY_BUFSIZ )
140140 {
141141 st_fail("echos: delay must be less than %g seconds!",
142142 DELAY_BUFSIZ / (float) effp->ininfo.rate );
@@ -177,7 +177,7 @@ int st_echos_start(eff_t effp) · 34 unmodified lines
177177 * Processed signed long samples from ibuf to obuf.
178178 * Return number of samples processed.
179179 */
180−int st_echos_flow(eff_t effp, const st_sample_t *ibuf, st_sample_t *obuf,
180+static int st_echos_flow(eff_t effp, const st_sample_t *ibuf, st_sample_t *obuf,
181181 st_size_t *isamp, st_size_t *osamp)
182182 {
183183 echos_t echos = (echos_t) effp->priv;
@@ -220,7 +220,7 @@ int st_echos_flow(eff_t effp, const st_sample_t *ibuf, st_sample_t *obuf, · 36 unmodified lines
220220 /*
221221 * Drain out reverb lines.
222222 */
223−int st_echos_drain(eff_t effp, st_sample_t *obuf, st_size_t *osamp)
223+static int st_echos_drain(eff_t effp, st_sample_t *obuf, st_size_t *osamp)
224224 {
225225 echos_t echos = (echos_t) effp->priv;
226226 double d_in, d_out;
@@ -266,7 +266,7 @@ int st_echos_drain(eff_t effp, st_sample_t *obuf, st_size_t *osamp) · 39 unmodified lines
266266 /*
267267 * Clean up echos effect.
268268 */
269−int st_echos_stop(eff_t effp)
269+static int st_echos_stop(eff_t effp)
270270 {
271271 echos_t echos = (echos_t) effp->priv;
272272

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