about summary refs log tree commit diff
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2006-10-14 16:25:29 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2006-10-14 16:25:29 +0000
commit545f6240cf70e7b26335c8a42e095fbc86888648 (patch)
tree5a4d608ecbb3c31011b879fd3784ab0e1638616b
parent9eba0808f20753cd15887b057f0d0fb20e663c03 (diff)
downloadnetpbm-mirror-545f6240cf70e7b26335c8a42e095fbc86888648.tar.gz
netpbm-mirror-545f6240cf70e7b26335c8a42e095fbc86888648.tar.xz
netpbm-mirror-545f6240cf70e7b26335c8a42e095fbc86888648.zip
Eliminate K-R function declarations
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@84 9d0c8265-081b-0410-96cb-a4ca84ce46f8
-rw-r--r--converter/other/pngtopnm.c22
-rw-r--r--converter/other/pnmtoddif.c4
-rw-r--r--converter/pbm/pbmtocmuwm.c6
-rw-r--r--converter/pbm/pbmtogem.c6
-rw-r--r--converter/pbm/pbmtogo.c6
-rw-r--r--converter/pbm/pbmtoicon.c6
-rw-r--r--converter/pbm/pbmtomgr.c6
-rw-r--r--converter/pbm/pbmtopi3.c6
-rw-r--r--converter/pbm/pbmtoptx.c6
-rw-r--r--converter/pbm/pbmtoybm.c6
-rw-r--r--converter/pgm/pgmtofs.c6
-rw-r--r--converter/pgm/pgmtolispm.c6
-rw-r--r--converter/ppm/ppmtoilbm.c42
-rw-r--r--converter/ppm/ppmtomitsu.c51
-rw-r--r--converter/ppm/ppmtopict.c7
-rw-r--r--converter/ppm/spctoppm.c7
-rw-r--r--generator/pbmupc.c17
-rw-r--r--generator/ppmpat.c52
-rw-r--r--lib/libpnm3.c46
-rw-r--r--lib/libppmcmap.c8
-rw-r--r--lib/libppmd.c10
21 files changed, 0 insertions, 326 deletions
diff --git a/converter/other/pngtopnm.c b/converter/other/pngtopnm.c
index bb8afb8d..2b88bd1e 100644
--- a/converter/other/pngtopnm.c
+++ b/converter/other/pngtopnm.c
@@ -240,23 +240,12 @@ gamma_correct(png_uint_16 const v,
 
 
 
-#ifdef __STDC__
 static int iscolor (png_color c)
-#else
-static int iscolor (c)
-png_color c;
-#endif
 {
   return c.red != c.green || c.green != c.blue;
 }
 
-#ifdef __STDC__
 static void save_text (png_info *info_ptr, FILE *tfp)
-#else
-static void save_text (info_ptr, tfp)
-png_info *info_ptr;
-FILE *tfp;
-#endif
 {
   int i, j, k;
 
@@ -285,12 +274,7 @@ FILE *tfp;
   }
 }
 
-#ifdef __STDC__
 static void show_time (png_info *info_ptr)
-#else
-static void show_time (info_ptr)
-png_info *info_ptr;
-#endif
 {
     static const char * const month[] = {
         "", "January", "February", "March", "April", "May", "June",
@@ -305,13 +289,7 @@ png_info *info_ptr;
   }
 }
 
-#ifdef __STDC__
 static void pngtopnm_error_handler (png_structp png_ptr, png_const_charp msg)
-#else
-static void pngtopnm_error_handler (png_ptr, msg)
-png_structp png_ptr;
-png_const_charp msg;
-#endif
 {
   jmpbuf_wrapper  *jmpbuf_ptr;
 
diff --git a/converter/other/pnmtoddif.c b/converter/other/pnmtoddif.c
index 65152865..3a910a7b 100644
--- a/converter/other/pnmtoddif.c
+++ b/converter/other/pnmtoddif.c
@@ -166,11 +166,7 @@ wr_int(unsigned char ** buffer, int val)
     } else {
         sign = val < 0 ? 0xff : 0x00;   /* Sign bits */
         length = 4;
-#ifdef __STDC__
         mask  = 0xffu << 24;
-#else
-        mask  = 0xff << 24;
-#endif
         while ((val & mask) == sign) {  /* Find the smallest representation */
             length--;
             mask >>= 8;
diff --git a/converter/pbm/pbmtocmuwm.c b/converter/pbm/pbmtocmuwm.c
index 64d7af40..f22ffff3 100644
--- a/converter/pbm/pbmtocmuwm.c
+++ b/converter/pbm/pbmtocmuwm.c
@@ -83,14 +83,8 @@ putinit( rows, cols )
     bitshift = 7;
     }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-    bit b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 8 )
 	putitem( );
diff --git a/converter/pbm/pbmtogem.c b/converter/pbm/pbmtogem.c
index 59f2b9cf..cefbdc95 100644
--- a/converter/pbm/pbmtogem.c
+++ b/converter/pbm/pbmtogem.c
@@ -129,14 +129,8 @@ putinit (rows, cols)
   linerepeat = -1;
 }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-    bit b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 8 )
 	putitem( );
diff --git a/converter/pbm/pbmtogo.c b/converter/pbm/pbmtogo.c
index a2349176..67fe5821 100644
--- a/converter/pbm/pbmtogo.c
+++ b/converter/pbm/pbmtogo.c
@@ -264,14 +264,8 @@ putinit()
   bitshift = 7;
 }
 
-#if __STDC__
 static void
 putbit(bit b)
-#else /*__STDC__*/
-static void
-putbit(b)
-bit b;
-#endif /*__STDC__*/
 {
   if (b == PBM_BLACK)
     item += 1 << bitshift;
diff --git a/converter/pbm/pbmtoicon.c b/converter/pbm/pbmtoicon.c
index 0e21c202..e61ccf13 100644
--- a/converter/pbm/pbmtoicon.c
+++ b/converter/pbm/pbmtoicon.c
@@ -80,14 +80,8 @@ putinit( )
     firstitem = 1;
     }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-bit b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 16 )
 	putitem( );
diff --git a/converter/pbm/pbmtomgr.c b/converter/pbm/pbmtomgr.c
index 7a6e7fc1..816e2a69 100644
--- a/converter/pbm/pbmtomgr.c
+++ b/converter/pbm/pbmtomgr.c
@@ -86,14 +86,8 @@ putinit( rows, cols )
     bitshift = 7;
     }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-    bit b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 8 )
 	putitem( );
diff --git a/converter/pbm/pbmtopi3.c b/converter/pbm/pbmtopi3.c
index 06023d7a..6a60af62 100644
--- a/converter/pbm/pbmtopi3.c
+++ b/converter/pbm/pbmtopi3.c
@@ -89,14 +89,8 @@ putinit( )
     bitshift = 7;
     }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-    bit b;
-#endif /*__STDC__*/
     {
     if (bitsperitem == 8)
 	putitem( );
diff --git a/converter/pbm/pbmtoptx.c b/converter/pbm/pbmtoptx.c
index 5031efcb..8cd60326 100644
--- a/converter/pbm/pbmtoptx.c
+++ b/converter/pbm/pbmtoptx.c
@@ -67,14 +67,8 @@ putinit( )
     bitshift = 0;
     }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-    bit b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 6 )
 	putitem( );
diff --git a/converter/pbm/pbmtoybm.c b/converter/pbm/pbmtoybm.c
index 1d2be3d9..508e8e92 100644
--- a/converter/pbm/pbmtoybm.c
+++ b/converter/pbm/pbmtoybm.c
@@ -80,14 +80,8 @@ putinit( cols, rows )
     bitshift = 0;
     }
 
-#if __STDC__
 static void
 putbit( bit b )
-#else /*__STDC__*/
-static void
-putbit( b )
-    bit b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 16 )
 	putitem( );
diff --git a/converter/pgm/pgmtofs.c b/converter/pgm/pgmtofs.c
index b34d77c4..53a2e7b3 100644
--- a/converter/pgm/pgmtofs.c
+++ b/converter/pgm/pgmtofs.c
@@ -128,14 +128,8 @@ putitem( )
     bitshift = 8 - bitspersample;
 }
 
-#if __STDC__
 static void
 putgray( gray g )
-#else /*__STDC__*/
-    static void
-putgray( g )
-    gray g;
-#endif /*__STDC__*/
 {
     if ( bitsperitem == 8 )
         putitem( );
diff --git a/converter/pgm/pgmtolispm.c b/converter/pgm/pgmtolispm.c
index 02f2fd1e..abb85494 100644
--- a/converter/pgm/pgmtolispm.c
+++ b/converter/pgm/pgmtolispm.c
@@ -115,14 +115,8 @@ depth_to_word_size (depth)	/* Lispm architecture specific - if a bitmap is writt
 
 
 
-#if __STDC__
 static void
 putval( gray b )
-#else /*__STDC__*/
-static void
-putval( b )
-gray b;
-#endif /*__STDC__*/
     {
     if ( bitsperitem == 32 )
 	putitem( );
diff --git a/converter/ppm/ppmtoilbm.c b/converter/ppm/ppmtoilbm.c
index 6c04c9be..c0d58edb 100644
--- a/converter/ppm/ppmtoilbm.c
+++ b/converter/ppm/ppmtoilbm.c
@@ -635,20 +635,9 @@ ppm_to_ham(fp, cols, rows, maxval, colormap, colors, cmapmaxval, hamplanes)
 
 
 static long
-#ifdef __STDC__
 do_ham_body(FILE *ifP, FILE *ofp, int cols, int rows,
             pixval maxval, pixval hammaxval, int nPlanes,
             pixel *colormap, int colors)
-#else
-do_ham_body(ifP, ofp, cols, rows, maxval, hammaxval, nPlanes, colormap, colors)
-    FILE *ifP, *ofp;
-    int cols, rows;
-    pixval maxval;      /* maxval of image color components */
-    pixval hammaxval;   /* maxval of HAM color changes */
-    int nPlanes;
-    pixel *colormap;
-    int colors;
-#endif
 {
     register int col, row, i;
     rawtype *raw_rowbuf;
@@ -876,16 +865,8 @@ ppm_to_deep(fp, cols, rows, maxval, bitspercolor)
 
 
 static long
-#if __STDC__
 do_deep_body(FILE *ifP, FILE *ofp, int cols, int rows, pixval maxval, 
              int bitspercolor)
-#else
-do_deep_body(ifP, ofp, cols, rows, maxval, bitspercolor)
-    FILE *ifP, *ofp;
-    int cols, rows;
-    pixval maxval;
-    int bitspercolor;
-#endif
 {
     register int row, col;
     pixel *pP;
@@ -1014,16 +995,8 @@ ppm_to_dcol(fp, cols, rows, maxval, dcol)
 
 
 static long
-#if __STDC__
 do_dcol_body(FILE *ifP, FILE *ofp, int cols, int rows, pixval maxval, 
              DirectColor *dcol)
-#else
-do_dcol_body(ifP, ofp, cols, rows, maxval, dcol)
-    FILE *ifP, *ofp;
-    int cols, rows;
-    pixval maxval;
-    DirectColor *dcol;
-#endif
 {
     register int row, col;
     pixel *pP;
@@ -1161,18 +1134,8 @@ ppm_to_std(fp, cols, rows, maxval, colormap, colors, cmapmaxval,
 
 
 static long
-#if __STDC__
 do_std_body(FILE *ifP, FILE *ofp, int cols, int rows, pixval maxval,
             pixel *colormap, int colors, int nPlanes)
-#else
-do_std_body(ifP, ofp, cols, rows, maxval, colormap, colors, nPlanes)
-    FILE *ifP, *ofp;
-    int cols, rows;
-    pixval maxval;
-    pixel *colormap;
-    int colors;
-    int nPlanes;
-#endif
 {
     register int row, col, i;
     pixel *pP;
@@ -1783,12 +1746,7 @@ runbyte1(size)
 /************ other utility functions ************/
 
 static void
-#if __STDC__
 put_big_short(short s)
-#else
-put_big_short(s)
-    short s;
-#endif
 {
     if ( pm_writebigshort( stdout, s ) == -1 )
         pm_error( "write error" );
diff --git a/converter/ppm/ppmtomitsu.c b/converter/ppm/ppmtomitsu.c
index 3934ae45..e8d6540a 100644
--- a/converter/ppm/ppmtomitsu.c
+++ b/converter/ppm/ppmtomitsu.c
@@ -41,7 +41,6 @@ typedef struct hashinfo {
         struct hashinfo *next;
 } hashinfo;
 
-#ifdef __STDC__
 static void lineputinit(int cols, int rows, int sharpness, int enlarge, int
                         copy, struct mediasize medias);
 static void frametransferinit(int cols, int rows, int sharpness, int enlarge,
@@ -52,28 +51,13 @@ static void lookuptabledata(int cols, int rows, int enlarge,
                             struct mediasize medias);
 static void check_and_rotate(int cols, int rows, int enlarge,
                              struct mediasize medias);
-#define CONST const
-#else /*__STDC__*/
-static int lineputinit();
-static int lookuptableinit();
-static int lookuptabledata();
-static int frametransferinit();
-static int check_and_rotate();
-#define CONST
-#endif
 
 #define cmd(arg)           fputc((arg), stdout)
 #define datum(arg)         fputc((char)(arg), stdout)
 #define data(arg,num)      fwrite((arg), sizeof(char), (num), stdout)
 
 
-#ifdef __STDC__
 int main(int argc, char *argv[] )
-#else
-int main( argc, argv )
-    int argc;
-    char* argv[];
-#endif
     {
     FILE             *ifp;
     /*hashinfo         colorhashtable[HASHSIZE];*/
@@ -365,16 +349,9 @@ int main( argc, argv )
     exit(0);
 }
 
-#ifdef __STDC__
 static void lineputinit(int cols, int rows,
                         int sharpness, int enlarge, int copy,
                         struct mediasize medias)
-#else /*__STDC__*/
-static int lineputinit(cols, rows, sharpness, enlarge, copy, medias)
-    int cols, rows;
-    int sharpness, enlarge, copy;
-    struct mediasize medias;
-#endif /*__STDC__*/
 {
     ONLINE;
     CLRMEM;
@@ -429,14 +406,8 @@ static int lineputinit(cols, rows, sharpness, enlarge, copy, medias)
     return;
 }
 
-#ifdef __STDC__
 static void lookuptableinit(int sharpness, int enlarge, int copy,
                             struct mediasize medias)
-#else /*__STDC__*/
-static int lookuptableinit(sharpness, enlarge, copy, medias)
-    int sharpness, enlarge, copy;
-    struct mediasize medias;
-#endif /*__STDC__*/
 {
     ONLINE;
     CLRMEM;
@@ -489,15 +460,8 @@ static int lookuptableinit(sharpness, enlarge, copy, medias)
     return;
 }
 
-#ifdef __STDC__
 static void lookuptabledata(int cols, int rows, int enlarge,
                                                         struct mediasize medias)
-#else /*__STDC__*/
-static int lookuptabledata(cols, rows, enlarge, medias)
-    int   rows, cols;
-    int   enlarge;
-    struct mediasize medias;
-#endif /*__STDC__*/
 {
     DONELOOKUPTABLE;
     check_and_rotate(cols, rows, enlarge, medias);
@@ -505,16 +469,8 @@ static int lookuptabledata(cols, rows, enlarge, medias)
     return;
 }
 
-#ifdef __STDC__
 static void frametransferinit(int cols, int rows, int sharpness,
                               int enlarge, int copy, struct mediasize medias)
-#else
-static int frametransferinit(cols, rows, sharpness, enlarge, copy, medias)
-
-    int     rows, cols;
-    int     sharpness, enlarge, copy;
-    struct mediasize medias;
-#endif
 {
     ONLINE;
     CLRMEM;
@@ -569,15 +525,8 @@ static int frametransferinit(cols, rows, sharpness, enlarge, copy, medias)
 }
 
 
-#ifdef __STDC__
 static void
 check_and_rotate(int cols, int rows, int enlarge, struct mediasize medias)
-#else
-static int
-check_and_rotate(cols, rows, enlarge, medias)
-    int cols, rows, enlarge;
-    struct mediasize medias;
-#endif
 {
     if (cols > rows) {
         ROTATEIMG(DOROTATE);                        /* rotate image */
diff --git a/converter/ppm/ppmtopict.c b/converter/ppm/ppmtopict.c
index e2428fb6..22456857 100644
--- a/converter/ppm/ppmtopict.c
+++ b/converter/ppm/ppmtopict.c
@@ -282,15 +282,8 @@ int i;
 	(void) putc(i & 0xff, fd);
 }
 
-#if __STDC__
 static void
 putLong( FILE *fd, long i )
-#else /*__STDC__*/
-static void
-putLong(fd, i)
-FILE *fd;
-long i;
-#endif /*__STDC__*/
 {
 	(void) putc((int)((i >> 24) & 0xff), fd);
 	(void) putc(((int)(i >> 16) & 0xff), fd);
diff --git a/converter/ppm/spctoppm.c b/converter/ppm/spctoppm.c
index 3eea7821..d2a48187 100644
--- a/converter/ppm/spctoppm.c
+++ b/converter/ppm/spctoppm.c
@@ -165,15 +165,8 @@ DoBitmap( ifp )
 	sscreen[i] = ( screen[i<<1] << 8 ) + ( 0xff & screen[(i<<1)+1] );
     }
 
-#if __STDC__
 static void
 DoChar( int n, char c )
-#else /*__STDC__*/
-static void
-DoChar( n, c )
-    int n;
-    char c;
-#endif /*__STDC__*/
     {
     int i;
 
diff --git a/generator/pbmupc.c b/generator/pbmupc.c
index 5f694a00..6ef75654 100644
--- a/generator/pbmupc.c
+++ b/generator/pbmupc.c
@@ -433,17 +433,8 @@ putdigit( d, bits, row0, col0 )
 	    bits[row0 + row][col0 + col] = digits[d][row][col];
     }
 
-#if __STDC__
 static int
 addlines( int d, bit** bits, int row0, int col0, int height, bit color )
-#else /*__STDC__*/
-static int
-addlines( d, bits, row0, col0, height, color )
-    int d;
-    bit** bits;
-    int row0, col0, height;
-    bit color;
-#endif /*__STDC__*/
     {
     switch ( d )
 	{
@@ -524,16 +515,8 @@ addlines( d, bits, row0, col0, height, color )
     return col0;
     }
 
-#if __STDC__
 static int
 rect( bit** bits, int row0, int col0, int height, int width, bit color )
-#else /*__STDC__*/
-static int
-rect( bits, row0, col0, height, width, color )
-    bit** bits;
-    int row0, col0, height, width;
-    bit color;
-#endif /*__STDC__*/
     {
     int row, col;
 
diff --git a/generator/ppmpat.c b/generator/ppmpat.c
index 7650bd01..6034b2db 100644
--- a/generator/ppmpat.c
+++ b/generator/ppmpat.c
@@ -218,14 +218,8 @@ random_color(pixval const maxval) {
 
 #define DARK_THRESH 0.25
 
-#if __STDC__
 static pixel
 random_bright_color( pixval maxval )
-#else /*__STDC__*/
-static pixel
-random_bright_color( maxval )
-    pixval maxval;
-#endif /*__STDC__*/
     {
     pixel p;
 
@@ -238,14 +232,8 @@ random_bright_color( maxval )
     return p;
     }
 
-#if __STDC__
 static pixel
 random_dark_color( pixval maxval )
-#else /*__STDC__*/
-static pixel
-random_dark_color( maxval )
-    pixval maxval;
-#endif /*__STDC__*/
     {
     pixel p;
 
@@ -313,16 +301,8 @@ gingham2( pixel** pixels, int cols, int rows, pixval maxval )
         average_drawproc, &forecolor );
     }
 
-#if __STDC__
 static void
 gingham3( pixel** pixels, int cols, int rows, pixval maxval )
-#else /*__STDC__*/
-static void
-gingham3( pixels, cols, rows, maxval )
-    pixel** pixels;
-    int cols, rows;
-    pixval maxval;
-#endif /*__STDC__*/
     {
     int colso4, rowso4;
     pixel backcolor, fore1color, fore2color;
@@ -362,16 +342,8 @@ gingham3( pixels, cols, rows, maxval )
         average_drawproc, &fore1color );
     }
 
-#if __STDC__
 static void
 madras( pixel** pixels, int cols, int rows, pixval maxval )
-#else /*__STDC__*/
-static void
-madras( pixels, cols, rows, maxval )
-    pixel** pixels;
-    int cols, rows;
-    pixval maxval;
-#endif /*__STDC__*/
     {
     int cols2, rows2, cols3, rows3, cols12, rows12, cols6a, rows6a, cols6b,
     rows6b;
@@ -493,16 +465,8 @@ madras( pixels, cols, rows, maxval )
         cols, rows3, average_drawproc, &fore2color );
     }
 
-#if __STDC__
 static void
 tartan( pixel** pixels, int cols, int rows, pixval maxval )
-#else /*__STDC__*/
-static void
-tartan( pixels, cols, rows, maxval )
-    pixel** pixels;
-    int cols, rows;
-    pixval maxval;
-#endif /*__STDC__*/
     {
     int cols1, rows1, cols3, rows3, cols10, rows10, cols5a, rows5a, cols5b,
     rows5b;
@@ -579,16 +543,8 @@ tartan( pixels, cols, rows, maxval )
 
 #define MAXPOLES 500
 
-#if __STDC__
 static void
 poles( pixel** pixels, int cols, int rows, pixval maxval )
-#else /*__STDC__*/
-static void
-poles( pixels, cols, rows, maxval )
-    pixel** pixels;
-    int cols, rows;
-    pixval maxval;
-#endif /*__STDC__*/
     {
     int poles, i, xs[MAXPOLES], ys[MAXPOLES], col, row;
     pixel colors[MAXPOLES];
@@ -730,16 +686,8 @@ sq_assign_colors(int     const circlecount,
 }
 
 
-#if __STDC__
 static void
 squig( pixel** pixels, int cols, int rows, pixval maxval )
-#else /*__STDC__*/
-static void
-squig( pixels, cols, rows, maxval )
-    pixel** pixels;
-    int cols, rows;
-    pixval maxval;
-#endif /*__STDC__*/
     {
     pixel color;
     int i, j, xc[SQ_POINTS], yc[SQ_POINTS], x0, y0, x1, y1, x2, y2, x3, y3;
diff --git a/lib/libpnm3.c b/lib/libpnm3.c
index c9c9a1b0..bc55ae3e 100644
--- a/lib/libpnm3.c
+++ b/lib/libpnm3.c
@@ -21,16 +21,8 @@
 #include "pbm.h"
 #include "libpbm.h"
 
-#if __STDC__
 xel
 pnm_backgroundxel( xel** xels, int cols, int rows, xelval maxval, int format )
-#else /*__STDC__*/
-xel
-pnm_backgroundxel( xels, cols, rows, maxval, format )
-    xel** xels;
-    int cols, rows, format;
-    xelval maxval;
-#endif /*__STDC__*/
     {
     xel bgxel, ul, ur, ll, lr;
 
@@ -93,16 +85,8 @@ pnm_backgroundxel( xels, cols, rows, maxval, format )
     return bgxel;
     }
 
-#if __STDC__
 xel
 pnm_backgroundxelrow( xel* xelrow, int cols, xelval maxval, int format )
-#else /*__STDC__*/
-xel
-pnm_backgroundxelrow( xelrow, cols, maxval, format )
-    xel* xelrow;
-    int cols, format;
-    xelval maxval;
-#endif /*__STDC__*/
     {
     xel bgxel, l, r;
 
@@ -158,15 +142,8 @@ pnm_backgroundxelrow( xelrow, cols, maxval, format )
     return bgxel;
     }
 
-#if __STDC__
 xel
 pnm_whitexel( xelval maxval, int format )
-#else /*__STDC__*/
-xel
-pnm_whitexel( maxval, format )
-    xelval maxval;
-    int format;
-#endif /*__STDC__*/
     {
     xel x;
 
@@ -191,15 +168,8 @@ pnm_whitexel( maxval, format )
     return x;
     }
 
-#if __STDC__
 xel
 pnm_blackxel( xelval maxval, int format )
-#else /*__STDC__*/
-xel
-pnm_blackxel( maxval, format )
-    xelval maxval;
-    int format;
-#endif /*__STDC__*/
     {
     xel x;
 
@@ -252,16 +222,8 @@ pnm_invertxel(xel*   const xP,
 
 
 
-#if __STDC__
 void
 pnm_promoteformat( xel** xels, int cols, int rows, xelval maxval, int format, xelval newmaxval, int newformat )
-#else /*__STDC__*/
-void
-pnm_promoteformat( xels, cols, rows, maxval, format, newmaxval, newformat )
-    xel** xels;
-    xelval maxval, newmaxval;
-    int cols, rows, format, newformat;
-#endif /*__STDC__*/
     {
     int row;
 
@@ -270,16 +232,8 @@ pnm_promoteformat( xels, cols, rows, maxval, format, newmaxval, newformat )
         xels[row], cols, maxval, format, newmaxval, newformat );
     }
 
-#if __STDC__
 void
 pnm_promoteformatrow( xel* xelrow, int cols, xelval maxval, int format, xelval newmaxval, int newformat )
-#else /*__STDC__*/
-void
-pnm_promoteformatrow( xelrow, cols, maxval, format, newmaxval, newformat )
-    xel* xelrow;
-    xelval maxval, newmaxval;
-    int cols, format, newformat;
-#endif /*__STDC__*/
     {
     register int col;
     register xel* xP;
diff --git a/lib/libppmcmap.c b/lib/libppmcmap.c
index c1243cb6..954488d7 100644
--- a/lib/libppmcmap.c
+++ b/lib/libppmcmap.c
@@ -774,15 +774,7 @@ ppm_findclosestcolor(const pixel * const colormap,
 
 
 void
-#if __STDC__
 ppm_colorrowtomapfile(FILE *ofp, pixel *colormap, int ncolors, pixval maxval)
-#else
-ppm_colorrowtomapfile(ofp, colormap, ncolors, maxval)
-    FILE *ofp;
-    pixel *colormap;
-    int ncolors;
-    pixval maxval;
-#endif
 {
     int i;
 
diff --git a/lib/libppmd.c b/lib/libppmd.c
index ac8b6dee..a6ff0059 100644
--- a/lib/libppmd.c
+++ b/lib/libppmd.c
@@ -941,12 +941,7 @@ static int extleft, exttop, extright, extbottom;  /* To accumulate extents */
 /*  ISIN  --  Return sine of an angle in integral degrees.  The
           value returned is 65536 times the sine.  */
 
-#if __STDC__
 static long isin(int deg)
-#else
-    static long isin(deg)
-    int deg;
-#endif
 {
     /* Domain reduce to 0 to 360 degrees. */
 
@@ -971,12 +966,7 @@ static long isin(int deg)
 /*  ICOS  --  Return cosine of an angle in integral degrees.  The
           value returned is 65536 times the cosine.  */
 
-#if __STDC__
 static long icos(int deg)
-#else
-    static long icos(deg)
-    int deg;
-#endif
 {
     return isin(deg + 90);
 }