ANSI-fication
diff --git a/Modules/audioop.c b/Modules/audioop.c
index cc5634d..73612cb 100644
--- a/Modules/audioop.c
+++ b/Modules/audioop.c
@@ -26,7 +26,6 @@
#if defined(__CHAR_UNSIGNED__)
#if defined(signed)
-!ERROR!; READ THE SOURCE FILE!;
/* This module currently does not work on systems where only unsigned
characters are available. Take it out of Setup. Sorry. */
#endif
@@ -95,8 +94,7 @@
#define CLIP 32635
static unsigned char
-st_linear_to_ulaw( sample )
- int sample;
+st_linear_to_ulaw(int sample)
{
static int exp_lut[256] = {0,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3,
4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,
@@ -162,9 +160,7 @@
static PyObject *AudioopError;
static PyObject *
-audioop_getsample(self, args)
- PyObject *self;
- PyObject *args;
+audioop_getsample(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0;
@@ -187,9 +183,7 @@
}
static PyObject *
-audioop_max(self, args)
- PyObject *self;
- PyObject *args;
+audioop_max(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0;
@@ -213,9 +207,7 @@
}
static PyObject *
-audioop_minmax(self, args)
- PyObject *self;
- PyObject *args;
+audioop_minmax(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0;
@@ -239,9 +231,7 @@
}
static PyObject *
-audioop_avg(self, args)
- PyObject *self;
- PyObject *args;
+audioop_avg(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0;
@@ -268,9 +258,7 @@
}
static PyObject *
-audioop_rms(self, args)
- PyObject *self;
- PyObject *args;
+audioop_rms(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0;
@@ -343,9 +331,7 @@
** is completely recalculated each step.
*/
static PyObject *
-audioop_findfit(self, args)
- PyObject *self;
- PyObject *args;
+audioop_findfit(PyObject *self, PyObject *args)
{
short *cp1, *cp2;
int len1, len2;
@@ -403,9 +389,7 @@
** See the comment for findfit for details.
*/
static PyObject *
-audioop_findfactor(self, args)
- PyObject *self;
- PyObject *args;
+audioop_findfactor(PyObject *self, PyObject *args)
{
short *cp1, *cp2;
int len1, len2;
@@ -435,9 +419,7 @@
** that contains the most energy.
*/
static PyObject *
-audioop_findmax(self, args)
- PyObject *self;
- PyObject *args;
+audioop_findmax(PyObject *self, PyObject *args)
{
short *cp1;
int len1, len2;
@@ -481,9 +463,7 @@
}
static PyObject *
-audioop_avgpp(self, args)
- PyObject *self;
- PyObject *args;
+audioop_avgpp(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0, prevval = 0, prevextremevalid = 0,
@@ -540,9 +520,7 @@
}
static PyObject *
-audioop_maxpp(self, args)
- PyObject *self;
- PyObject *args;
+audioop_maxpp(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0, prevval = 0, prevextremevalid = 0,
@@ -595,9 +573,7 @@
}
static PyObject *
-audioop_cross(self, args)
- PyObject *self;
- PyObject *args;
+audioop_cross(PyObject *self, PyObject *args)
{
signed char *cp;
int len, size, val = 0;
@@ -624,9 +600,7 @@
}
static PyObject *
-audioop_mul(self, args)
- PyObject *self;
- PyObject *args;
+audioop_mul(PyObject *self, PyObject *args)
{
signed char *cp, *ncp;
int len, size, val = 0;
@@ -667,9 +641,7 @@
}
static PyObject *
-audioop_tomono(self, args)
- PyObject *self;
- PyObject *args;
+audioop_tomono(PyObject *self, PyObject *args)
{
signed char *cp, *ncp;
int len, size, val1 = 0, val2 = 0;
@@ -713,9 +685,7 @@
}
static PyObject *
-audioop_tostereo(self, args)
- PyObject *self;
- PyObject *args;
+audioop_tostereo(PyObject *self, PyObject *args)
{
signed char *cp, *ncp;
int len, size, val1, val2, val = 0;
@@ -767,9 +737,7 @@
}
static PyObject *
-audioop_add(self, args)
- PyObject *self;
- PyObject *args;
+audioop_add(PyObject *self, PyObject *args)
{
signed char *cp1, *cp2, *ncp;
int len1, len2, size, val1 = 0, val2 = 0, maxval, newval;
@@ -822,9 +790,7 @@
}
static PyObject *
-audioop_bias(self, args)
- PyObject *self;
- PyObject *args;
+audioop_bias(PyObject *self, PyObject *args)
{
signed char *cp, *ncp;
int len, size, val = 0;
@@ -860,9 +826,7 @@
}
static PyObject *
-audioop_reverse(self, args)
- PyObject *self;
- PyObject *args;
+audioop_reverse(PyObject *self, PyObject *args)
{
signed char *cp;
unsigned char *ncp;
@@ -899,9 +863,7 @@
}
static PyObject *
-audioop_lin2lin(self, args)
- PyObject *self;
- PyObject *args;
+audioop_lin2lin(PyObject *self, PyObject *args)
{
signed char *cp;
unsigned char *ncp;
@@ -949,9 +911,7 @@
}
static PyObject *
-audioop_ratecv(self, args)
- PyObject *self;
- PyObject *args;
+audioop_ratecv(PyObject *self, PyObject *args)
{
char *cp, *ncp;
int len, size, nchannels, inrate, outrate, weightA, weightB;
@@ -1090,9 +1050,7 @@
}
static PyObject *
-audioop_lin2ulaw(self, args)
- PyObject *self;
- PyObject *args;
+audioop_lin2ulaw(PyObject *self, PyObject *args)
{
signed char *cp;
unsigned char *ncp;
@@ -1125,9 +1083,7 @@
}
static PyObject *
-audioop_ulaw2lin(self, args)
- PyObject *self;
- PyObject *args;
+audioop_ulaw2lin(PyObject *self, PyObject *args)
{
unsigned char *cp;
unsigned char cval;
@@ -1162,9 +1118,7 @@
}
static PyObject *
-audioop_lin2adpcm(self, args)
- PyObject *self;
- PyObject *args;
+audioop_lin2adpcm(PyObject *self, PyObject *args)
{
signed char *cp;
signed char *ncp;
@@ -1273,9 +1227,7 @@
}
static PyObject *
-audioop_adpcm2lin(self, args)
- PyObject *self;
- PyObject *args;
+audioop_adpcm2lin(PyObject *self, PyObject *args)
{
signed char *cp;
signed char *ncp;