[Debburn-changes] r368 - in nonameyet/branches/cleanup: btcflash cdda2wav cdrecord include libedc libhfs_iso libparanoia librscg libscg libscg/scg libunls mkisofs mkisofs/diag readcd rscsi scgcheck scgskeleton

Christian Fromme kaner-guest at costa.debian.org
Thu Oct 12 21:38:32 CEST 2006


Author: kaner-guest
Date: 2006-10-12 19:38:29 +0000 (Thu, 12 Oct 2006)
New Revision: 368

Modified:
   nonameyet/branches/cleanup/btcflash/btcflash.c
   nonameyet/branches/cleanup/btcflash/skel.c
   nonameyet/branches/cleanup/cdda2wav/aifc.c
   nonameyet/branches/cleanup/cdda2wav/aiff.c
   nonameyet/branches/cleanup/cdda2wav/base64.h
   nonameyet/branches/cleanup/cdda2wav/cd_extra.c
   nonameyet/branches/cleanup/cdda2wav/cd_text.c
   nonameyet/branches/cleanup/cdda2wav/cdda2wav.c
   nonameyet/branches/cleanup/cdda2wav/cdda2wav.h
   nonameyet/branches/cleanup/cdda2wav/interface.c
   nonameyet/branches/cleanup/cdda2wav/interface.h
   nonameyet/branches/cleanup/cdda2wav/ioctl.c
   nonameyet/branches/cleanup/cdda2wav/ioctl.h
   nonameyet/branches/cleanup/cdda2wav/md5.h
   nonameyet/branches/cleanup/cdda2wav/md5c.c
   nonameyet/branches/cleanup/cdda2wav/raw.c
   nonameyet/branches/cleanup/cdda2wav/resample.c
   nonameyet/branches/cleanup/cdda2wav/resample.h
   nonameyet/branches/cleanup/cdda2wav/ringbuff.c
   nonameyet/branches/cleanup/cdda2wav/ringbuff.h
   nonameyet/branches/cleanup/cdda2wav/scsi_cmds.c
   nonameyet/branches/cleanup/cdda2wav/scsi_cmds.h
   nonameyet/branches/cleanup/cdda2wav/semshm.c
   nonameyet/branches/cleanup/cdda2wav/semshm.h
   nonameyet/branches/cleanup/cdda2wav/setuid.c
   nonameyet/branches/cleanup/cdda2wav/setuid.h
   nonameyet/branches/cleanup/cdda2wav/sha.h
   nonameyet/branches/cleanup/cdda2wav/sha_func.c
   nonameyet/branches/cleanup/cdda2wav/sndconfig.c
   nonameyet/branches/cleanup/cdda2wav/sndconfig.h
   nonameyet/branches/cleanup/cdda2wav/sndfile.h
   nonameyet/branches/cleanup/cdda2wav/sun.c
   nonameyet/branches/cleanup/cdda2wav/toc.c
   nonameyet/branches/cleanup/cdda2wav/toc.h
   nonameyet/branches/cleanup/cdda2wav/wav.c
   nonameyet/branches/cleanup/cdrecord/audiosize.c
   nonameyet/branches/cleanup/cdrecord/auinfo.c
   nonameyet/branches/cleanup/cdrecord/cd_misc.c
   nonameyet/branches/cleanup/cdrecord/cdr_drv.c
   nonameyet/branches/cleanup/cdrecord/cdrecord.c
   nonameyet/branches/cleanup/cdrecord/cdrecord.h
   nonameyet/branches/cleanup/cdrecord/cdtext.c
   nonameyet/branches/cleanup/cdrecord/clone.c
   nonameyet/branches/cleanup/cdrecord/crc16.c
   nonameyet/branches/cleanup/cdrecord/crc16.h
   nonameyet/branches/cleanup/cdrecord/cue.c
   nonameyet/branches/cleanup/cdrecord/defaults.c
   nonameyet/branches/cleanup/cdrecord/diskid.c
   nonameyet/branches/cleanup/cdrecord/drv_7501.c
   nonameyet/branches/cleanup/cdrecord/drv_jvc.c
   nonameyet/branches/cleanup/cdrecord/drv_mmc.c
   nonameyet/branches/cleanup/cdrecord/drv_philips.c
   nonameyet/branches/cleanup/cdrecord/drv_simul.c
   nonameyet/branches/cleanup/cdrecord/drv_sony.c
   nonameyet/branches/cleanup/cdrecord/fifo.c
   nonameyet/branches/cleanup/cdrecord/getnum.c
   nonameyet/branches/cleanup/cdrecord/isosize.c
   nonameyet/branches/cleanup/cdrecord/misc.c
   nonameyet/branches/cleanup/cdrecord/modes.c
   nonameyet/branches/cleanup/cdrecord/movesect.c
   nonameyet/branches/cleanup/cdrecord/movesect.h
   nonameyet/branches/cleanup/cdrecord/scsi_cdr.c
   nonameyet/branches/cleanup/cdrecord/scsi_cdr_mmc4.c
   nonameyet/branches/cleanup/cdrecord/scsi_mmc.c
   nonameyet/branches/cleanup/cdrecord/scsi_mmc4.c
   nonameyet/branches/cleanup/cdrecord/scsi_scan.c
   nonameyet/branches/cleanup/cdrecord/scsi_scan.h
   nonameyet/branches/cleanup/cdrecord/sector.c
   nonameyet/branches/cleanup/cdrecord/subchan.c
   nonameyet/branches/cleanup/cdrecord/wm_packet.c
   nonameyet/branches/cleanup/cdrecord/wm_session.c
   nonameyet/branches/cleanup/cdrecord/wm_track.c
   nonameyet/branches/cleanup/cdrecord/xio.c
   nonameyet/branches/cleanup/cdrecord/xio.h
   nonameyet/branches/cleanup/include/device.h
   nonameyet/branches/cleanup/include/getargs.h
   nonameyet/branches/cleanup/include/libport.h
   nonameyet/branches/cleanup/include/librmt.h
   nonameyet/branches/cleanup/include/patmatch.h
   nonameyet/branches/cleanup/include/schily.h
   nonameyet/branches/cleanup/include/sigblk.h
   nonameyet/branches/cleanup/include/strdefs.h
   nonameyet/branches/cleanup/include/termcap.h
   nonameyet/branches/cleanup/include/unixstd.h
   nonameyet/branches/cleanup/include/unls.h
   nonameyet/branches/cleanup/libedc/ecc.h
   nonameyet/branches/cleanup/libedc/edc_ecc.c
   nonameyet/branches/cleanup/libedc/edcspeed.c
   nonameyet/branches/cleanup/libhfs_iso/block.h
   nonameyet/branches/cleanup/libhfs_iso/btree.h
   nonameyet/branches/cleanup/libhfs_iso/data.c
   nonameyet/branches/cleanup/libhfs_iso/data.h
   nonameyet/branches/cleanup/libhfs_iso/file.h
   nonameyet/branches/cleanup/libhfs_iso/hfs.h
   nonameyet/branches/cleanup/libhfs_iso/internal.h
   nonameyet/branches/cleanup/libhfs_iso/low.h
   nonameyet/branches/cleanup/libhfs_iso/node.h
   nonameyet/branches/cleanup/libhfs_iso/record.h
   nonameyet/branches/cleanup/libhfs_iso/volume.c
   nonameyet/branches/cleanup/libhfs_iso/volume.h
   nonameyet/branches/cleanup/libparanoia/cdda_paranoia.h
   nonameyet/branches/cleanup/libparanoia/gap.c
   nonameyet/branches/cleanup/libparanoia/gap.h
   nonameyet/branches/cleanup/libparanoia/isort.c
   nonameyet/branches/cleanup/libparanoia/isort.h
   nonameyet/branches/cleanup/libparanoia/overlap.c
   nonameyet/branches/cleanup/libparanoia/overlap.h
   nonameyet/branches/cleanup/libparanoia/p_block.c
   nonameyet/branches/cleanup/libparanoia/p_block.h
   nonameyet/branches/cleanup/libparanoia/paranoia.c
   nonameyet/branches/cleanup/libparanoia/pmalloc.h
   nonameyet/branches/cleanup/librscg/scsi-remote.c
   nonameyet/branches/cleanup/libscg/rdummy.c
   nonameyet/branches/cleanup/libscg/scg/scgops.h
   nonameyet/branches/cleanup/libscg/scg/scsitransp.h
   nonameyet/branches/cleanup/libscg/scgsettarget.c
   nonameyet/branches/cleanup/libscg/scgtimes.c
   nonameyet/branches/cleanup/libscg/scgtimes.h
   nonameyet/branches/cleanup/libscg/scsi-aix.c
   nonameyet/branches/cleanup/libscg/scsi-amigaos.c
   nonameyet/branches/cleanup/libscg/scsi-apollo.c
   nonameyet/branches/cleanup/libscg/scsi-beos.c
   nonameyet/branches/cleanup/libscg/scsi-bsd-os.c
   nonameyet/branches/cleanup/libscg/scsi-bsd.c
   nonameyet/branches/cleanup/libscg/scsi-dos.c
   nonameyet/branches/cleanup/libscg/scsi-hpux.c
   nonameyet/branches/cleanup/libscg/scsi-linux-ata.c
   nonameyet/branches/cleanup/libscg/scsi-linux-pg.c
   nonameyet/branches/cleanup/libscg/scsi-linux-sg.c
   nonameyet/branches/cleanup/libscg/scsi-mac-iokit.c
   nonameyet/branches/cleanup/libscg/scsi-next.c
   nonameyet/branches/cleanup/libscg/scsi-openserver.c
   nonameyet/branches/cleanup/libscg/scsi-os2.c
   nonameyet/branches/cleanup/libscg/scsi-osf.c
   nonameyet/branches/cleanup/libscg/scsi-qnx.c
   nonameyet/branches/cleanup/libscg/scsi-sgi.c
   nonameyet/branches/cleanup/libscg/scsi-sun.c
   nonameyet/branches/cleanup/libscg/scsi-unixware.c
   nonameyet/branches/cleanup/libscg/scsi-vms.c
   nonameyet/branches/cleanup/libscg/scsi-wnt.c
   nonameyet/branches/cleanup/libscg/scsierrs.c
   nonameyet/branches/cleanup/libscg/scsihack.c
   nonameyet/branches/cleanup/libscg/scsihelp.c
   nonameyet/branches/cleanup/libscg/scsiopen.c
   nonameyet/branches/cleanup/libscg/scsitransp.c
   nonameyet/branches/cleanup/libunls/nls.h
   nonameyet/branches/cleanup/libunls/nls_base.c
   nonameyet/branches/cleanup/libunls/nls_file.c
   nonameyet/branches/cleanup/libunls/nls_iconv.c
   nonameyet/branches/cleanup/mkisofs/apple.c
   nonameyet/branches/cleanup/mkisofs/apple.h
   nonameyet/branches/cleanup/mkisofs/apple_driver.c
   nonameyet/branches/cleanup/mkisofs/boot-alpha.c
   nonameyet/branches/cleanup/mkisofs/boot-hppa.c
   nonameyet/branches/cleanup/mkisofs/boot-mips.c
   nonameyet/branches/cleanup/mkisofs/boot-mipsel.c
   nonameyet/branches/cleanup/mkisofs/boot.c
   nonameyet/branches/cleanup/mkisofs/desktop.c
   nonameyet/branches/cleanup/mkisofs/diag/dump.c
   nonameyet/branches/cleanup/mkisofs/diag/isodebug.c
   nonameyet/branches/cleanup/mkisofs/diag/isodump.c
   nonameyet/branches/cleanup/mkisofs/diag/isoinfo.c
   nonameyet/branches/cleanup/mkisofs/diag/isovfy.c
   nonameyet/branches/cleanup/mkisofs/dvd_file.c
   nonameyet/branches/cleanup/mkisofs/dvd_file.h
   nonameyet/branches/cleanup/mkisofs/dvd_reader.c
   nonameyet/branches/cleanup/mkisofs/dvd_reader.h
   nonameyet/branches/cleanup/mkisofs/eltorito.c
   nonameyet/branches/cleanup/mkisofs/endian.c
   nonameyet/branches/cleanup/mkisofs/endianconv.h
   nonameyet/branches/cleanup/mkisofs/exclude.c
   nonameyet/branches/cleanup/mkisofs/exclude.h
   nonameyet/branches/cleanup/mkisofs/files.c
   nonameyet/branches/cleanup/mkisofs/fnmatch.c
   nonameyet/branches/cleanup/mkisofs/fnmatch.h
   nonameyet/branches/cleanup/mkisofs/getopt.c
   nonameyet/branches/cleanup/mkisofs/getopt1.c
   nonameyet/branches/cleanup/mkisofs/hash.c
   nonameyet/branches/cleanup/mkisofs/ifo_read.c
   nonameyet/branches/cleanup/mkisofs/ifo_read.h
   nonameyet/branches/cleanup/mkisofs/joliet.c
   nonameyet/branches/cleanup/mkisofs/mac_label.c
   nonameyet/branches/cleanup/mkisofs/match.c
   nonameyet/branches/cleanup/mkisofs/match.h
   nonameyet/branches/cleanup/mkisofs/md5.c
   nonameyet/branches/cleanup/mkisofs/mkisofs.c
   nonameyet/branches/cleanup/mkisofs/mkisofs.h
   nonameyet/branches/cleanup/mkisofs/multi.c
   nonameyet/branches/cleanup/mkisofs/name.c
   nonameyet/branches/cleanup/mkisofs/rock.c
   nonameyet/branches/cleanup/mkisofs/scsi.c
   nonameyet/branches/cleanup/mkisofs/scsi.h
   nonameyet/branches/cleanup/mkisofs/stream.c
   nonameyet/branches/cleanup/mkisofs/tree.c
   nonameyet/branches/cleanup/mkisofs/udf.c
   nonameyet/branches/cleanup/mkisofs/udf.h
   nonameyet/branches/cleanup/mkisofs/volume.c
   nonameyet/branches/cleanup/mkisofs/write.c
   nonameyet/branches/cleanup/readcd/io.c
   nonameyet/branches/cleanup/readcd/readcd.c
   nonameyet/branches/cleanup/rscsi/rscsi.c
   nonameyet/branches/cleanup/scgcheck/dmaresid.c
   nonameyet/branches/cleanup/scgcheck/scgcheck.c
   nonameyet/branches/cleanup/scgcheck/scgcheck.h
   nonameyet/branches/cleanup/scgcheck/sense.c
   nonameyet/branches/cleanup/scgskeleton/skel.c
Log:
* Cleaned up K&R function definitions [except libschily]
* Cleaned up __PR makros [except libschily]


Modified: nonameyet/branches/cleanup/btcflash/btcflash.c
===================================================================
--- nonameyet/branches/cleanup/btcflash/btcflash.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/btcflash/btcflash.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -46,13 +46,13 @@
 #endif
 
 #define	FLASHSIZE	0x100000	/* BTC flash is 1MB */
+   
+unsigned char	*loadfirmware(const char *);
+int				getbyte(char **);
+unsigned short	calcsum(unsigned char *);
+static int		btcmain(SCSI *scgp, const char *fwfile);
 
-unsigned char *loadfirmware(const char *);
-int getbyte(char **);
-unsigned short calcsum(unsigned char *);
-static int btcmain		__PR((SCSI *scgp, const char *fwfile));
 
-
 unsigned char *
 loadfirmware(const char *firmware)
 {

Modified: nonameyet/branches/cleanup/btcflash/skel.c
===================================================================
--- nonameyet/branches/cleanup/btcflash/skel.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/btcflash/skel.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -63,8 +63,8 @@
 
 char	skel_version[] = "1.1";
 
-extern	BOOL	getlong		__PR((char *, long *, long, long));
-extern	BOOL	getint		__PR((char *, int *, int, int));
+extern	BOOL	getlong(char *, long *, long, long);
+extern	BOOL	getint(char *, int *, int, int);
 
 struct exargs {
 	SCSI	*scgp;
@@ -74,15 +74,15 @@
 	char	oerr[3];
 } exargs;
 
-static	void	usage		__PR((int ret));
-int	main		__PR((int ac, char **av));
-static	void	intr		__PR((int sig));
-static	void	exscsi		__PR((int excode, void *arg));
-static	void	excdr		__PR((int excode, void *arg));
-static	int	prstats		__PR((void));
-static	int	prstats_silent	__PR((void));
-static	void	doit		__PR((SCSI *scgp));
-static	void	dofile		__PR((SCSI *scgp, char *filename));
+static	void	usage(int ret);
+static	void	intr(int sig);
+static	void	exscsi(int excode, void *arg);
+static	void	excdr(int excode, void *arg);
+static	int	prstats(void);
+static	int	prstats_silent(void);
+static	void	doit(SCSI *scgp);
+static	void	dofile(SCSI *scgp, char *filename);
+static 	int 	btcmain(SCSI *scgp, const char *fwfile);
 
 struct timeval	starttime;
 struct timeval	stoptime;
@@ -475,7 +475,6 @@
 	}
 }
 
-static int btcmain		__PR((SCSI *scgp, const char *fwfile));
 
 static void
 dofile(SCSI *scgp, char *filename)

Modified: nonameyet/branches/cleanup/cdda2wav/aifc.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/aifc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/aifc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -83,12 +83,28 @@
 
 static AIFCHDR AifcHdr;
 
+/* Prototypes */
+static int Format_samplerate(unsigned long rate, unsigned char the_rate[10]);
+static int InitSound(int audio, long channels, unsigned long rate, 
+							long nBitsPerSample, unsigned long expected_bytes );
+static int ExitSound(int audio, unsigned long nBytesDone);
+static unsigned long GetHdrSize(void);
+static unsigned long InSizeToOutSize(unsigned long BytesToDo);
 
+struct soundfile aifcsound =
+{
+	InitSound,		/* init header method */
+	ExitSound,		/* exit header method */
+	GetHdrSize,		/* report header size method */
+	/* get sound samples out */
+	(int (*)(int audio, unsigned char *buf, unsigned long BytesToDo))write,
+	InSizeToOutSize,	/* compressed? output file size */
+	1						/* needs big endian samples */
+};
+
 /* format the sample rate into an
    bigendian 10-byte IEEE-754 floating point number
  */
-static int Format_samplerate __PR((unsigned long rate, unsigned char the_rate[10]));
-
 static int Format_samplerate(unsigned long rate, unsigned char the_rate[10])
 {
   int i;
@@ -115,7 +131,6 @@
   return 0;
 }
 
-static int InitSound __PR(( int audio, long channels, unsigned long rate, long nBitsPerSample, unsigned long expected_bytes ));
 
 static int InitSound(int audio, long channels, unsigned long rate, 
                      long nBitsPerSample, unsigned long expected_bytes)
@@ -165,8 +180,6 @@
   return write (audio, &AifcHdr, sizeof (AifcHdr));
 }
 
-static int ExitSound __PR(( int audio, unsigned long nBytesDone ));
-
 static int ExitSound(int audio, unsigned long nBytesDone)
 {
   UINT4 tmp;
@@ -193,26 +206,13 @@
   return write (audio, &AifcHdr, sizeof (AifcHdr));
 }
 
-static unsigned long GetHdrSize __PR(( void ));
-
 static unsigned long GetHdrSize()
 {
   return sizeof( AifcHdr );
 }
 
-static unsigned long InSizeToOutSize __PR(( unsigned long BytesToDo ));
-
 static unsigned long InSizeToOutSize(unsigned long  BytesToDo)
 {
         return BytesToDo;
 }
 
-struct soundfile aifcsound =
-{
-	InitSound,		/* init header method */
-	ExitSound,		/* exit header method */
-	GetHdrSize,		/* report header size method */
-	(int (*) __PR(( int audio, unsigned char *buf, unsigned long BytesToDo ))) write,			/* get sound samples out */
-	InSizeToOutSize,	/* compressed? output file size */
-	1			/* needs big endian samples */
-};

Modified: nonameyet/branches/cleanup/cdda2wav/aiff.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/aiff.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/aiff.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -70,11 +70,18 @@
 
 static AIFFHDR AiffHdr;
 
+/* Prototypes */
+static int Format_samplerate(unsigned long rate, unsigned char the_rate[10]);
+static int InitSound(int audio, long channels, unsigned long rate, 
+							long nBitsPerSample, unsigned long expected_bytes);
+static int ExitSound(int audio, unsigned long nBytesDone);
+static unsigned long GetHdrSize(void);
+static unsigned long InSizeToOutSize(unsigned long BytesToDo);
+
+
 /* format the sample rate into an
    bigendian 10-byte IEEE-754 floating point number
  */
-static int Format_samplerate __PR((unsigned long rate, unsigned char the_rate[10]));
-
 static int Format_samplerate(unsigned long rate, unsigned char the_rate[10])
 {
   int i;
@@ -101,8 +108,6 @@
   return 0;
 }
 
-static int InitSound __PR(( int audio, long channels, unsigned long rate, long nBitsPerSample, unsigned long expected_bytes ));
-
 static int InitSound(int audio, long channels, unsigned long rate, 
                      long nBitsPerSample, unsigned long expected_bytes)
 {
@@ -138,8 +143,6 @@
   return write (audio, &AiffHdr, sizeof (AiffHdr));
 }
 
-static int ExitSound __PR(( int audio, unsigned long nBytesDone ));
-
 static int ExitSound(int audio, unsigned long nBytesDone )
 {
   UINT4 tmp;
@@ -166,15 +169,11 @@
   return write (audio, &AiffHdr, sizeof (AiffHdr));
 }
 
-static unsigned long GetHdrSize __PR(( void ));
-
 static unsigned long GetHdrSize()
 {
   return sizeof( AiffHdr );
 }
 
-static unsigned long InSizeToOutSize __PR(( unsigned long BytesToDo ));
-
 static unsigned long InSizeToOutSize(unsigned long BytesToDo)
 {
         return BytesToDo;
@@ -185,7 +184,10 @@
 	InitSound,		/* init header method */
 	ExitSound,		/* exit header method */
 	GetHdrSize,		/* report header size method */
-	(int (*) __PR(( int audio, unsigned char *buf, unsigned long BytesToDo ))) write,			/* get sound samples out */
+	/* get sound samples out */
+	(int (*)(int audio, unsigned char *buf, unsigned long BytesToDo))write,
 	InSizeToOutSize,	/* compressed? output file size */
-	1			/* needs big endian samples */
+	1						/* needs big endian samples */
 };
+
+

Modified: nonameyet/branches/cleanup/cdda2wav/base64.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/base64.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/base64.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -78,6 +78,6 @@
 #ifndef BASE64_H
 #define BASE64_H
 
-unsigned char *rfc822_binary __PR((char *src,unsigned long srcl,unsigned long *len));
+unsigned char *rfc822_binary(char *src,unsigned long srcl,unsigned long *len);
 
 #endif

Modified: nonameyet/branches/cleanup/cdda2wav/cd_extra.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/cd_extra.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/cd_extra.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -17,7 +17,7 @@
 
 #include <ctype.h>
 
-static unsigned long Read_CD_Extra_File __PR((unsigned char *Extra_buf, unsigned long sector));
+static unsigned long Read_CD_Extra_File(unsigned char *Extra_buf, unsigned long sector);
 
 static unsigned long
 Read_CD_Extra_File(unsigned char *Extra_buf, unsigned long sector)
@@ -102,7 +102,7 @@
  * Of course, there are a lot dubious cd extras, which don't care :-(((
  * As an alternative method, we try reading through the iso9660 file system...
  */
-static int Read_CD_Extra_Info __PR(( unsigned long sector));
+static int Read_CD_Extra_Info(unsigned long sector);
 static int Read_CD_Extra_Info(unsigned long sector)
 {
   unsigned i;
@@ -149,7 +149,7 @@
   return 0;
 }
 
-static void Read_Subinfo __PR(( unsigned pos, unsigned length));
+static void Read_Subinfo(unsigned pos, unsigned length);
 static void Read_Subinfo(unsigned pos, unsigned length)
 {
   unsigned num_infos, num;

Modified: nonameyet/branches/cleanup/cdda2wav/cd_text.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/cd_text.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/cd_text.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -58,10 +58,8 @@
 
 #define SUBSIZE	18*8
 
-static unsigned short updcrc __PR((
-	    unsigned int    p_crc,
-            register unsigned char   *cp,
-            register size_t  cnt));
+static unsigned short updcrc(unsigned int p_crc, register unsigned char *cp,
+       							  register size_t cnt);
 
 static unsigned short updcrc(unsigned int p_crc, register unsigned char *cp, 
                              register size_t cnt)
@@ -73,7 +71,7 @@
       return( crc );
 }
 
-static unsigned short calcCRC __PR((unsigned char *buf, unsigned bsize));
+static unsigned short calcCRC(unsigned char *buf, unsigned bsize);
 
 static unsigned short calcCRC(unsigned char *buf, unsigned bsize)
 {
@@ -91,7 +89,7 @@
         0x80,
 };
 
-static int flip_error_corr __PR((unsigned char *b, int crc));
+static int flip_error_corr(unsigned char *b, int crc);
 
 static int flip_error_corr(unsigned char *b, int crc)
 {
@@ -112,7 +110,7 @@
 }
 
 
-static int cdtext_crc_ok __PR((cdtextpackdata *c));
+static int cdtext_crc_ok(cdtextpackdata *c);
 
 static int cdtext_crc_ok(cdtextpackdata *c)
 {
@@ -154,7 +152,7 @@
 #define DETAILED 0
 
 #if	DETAILED
-static void dump_binary __PR((cdtextpackdata *c));
+static void dump_binary(cdtextpackdata *c);
 
 static void dump_binary(cdtextpackdata *c)
 {
@@ -178,7 +176,8 @@
 }
 #endif
 
-static int process_header __PR((cdtextpackdata *c, unsigned tracknr, int dbcc, unsigned char *line));
+static int process_header(cdtextpackdata *c, unsigned tracknr, int dbcc, 
+								  unsigned char *line);
 
 static int process_header(cdtextpackdata *c, unsigned tracknr, int dbcc, 
                           unsigned char *line)

Modified: nonameyet/branches/cleanup/cdda2wav/cdda2wav.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/cdda2wav.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/cdda2wav.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -138,17 +138,21 @@
 #endif
 #include "defaults.h"
 
-static void RestrictPlaybackRate	__PR((long newrate));
-static void output_indices		__PR((FILE *fp, index_list *p, unsigned trackstart));
-static int write_info_file		__PR((char *fname_baseval, unsigned int track, unsigned long SamplesDone, int numbered));
-static void CloseAudio			__PR((int channels_val, unsigned long nSamples, struct soundfile *audio_out));
-static void CloseAll			__PR((void));
-static void OpenAudio			__PR((char *fname, double rate, long nBitsPerSample, long channels_val, unsigned long expected_bytes, struct soundfile*audio_out));
-static void set_offset			__PR((myringbuff *p, int offset));
-static int get_offset			__PR((myringbuff *p));
-static void usage			__PR((void));
-static void init_globals		__PR((void));
-static	int	is_fifo			__PR((char * filename));
+static void RestrictPlaybackRate(long newrate);
+static void output_indices(FILE *fp, index_list *p, unsigned trackstart);
+static int 	write_info_file(char *fname_baseval, unsigned int track, 
+									 unsigned long SamplesDone, int numbered);
+static void CloseAudio(int channels_val, unsigned long nSamples, 
+							  struct soundfile *audio_out);
+static void CloseAll(void);
+static void OpenAudio(char *fname, double rate, long nBitsPerSample, 
+							 long channels_val, unsigned long expected_bytes, 
+							 struct soundfile*audio_out);
+static void set_offset(myringbuff *p, int offset);
+static int 	get_offset(myringbuff *p);
+static void usage(void);
+static void init_globals(void);
+static int	is_fifo(char *filename);
 
 
 /* Rules:
@@ -188,7 +192,7 @@
 static unsigned int current_track;
 static int bulk = 0;
 
-unsigned int get_current_track __PR((void));
+unsigned int get_current_track(void);
 
 unsigned int get_current_track()
 {
@@ -219,14 +223,14 @@
 static int argc3;
 static char **argv2;
 
-static void reset_name_iterator __PR((void));
-static void reset_name_iterator ()
+static void reset_name_iterator(void);
+static void reset_name_iterator()
 {
 	argv2 -= argc3 - argc2;
 	argc2 = argc3;
 }
 
-static char *get_next_name __PR((void));
+static char *get_next_name(void);
 static char *get_next_name()
 {
 	if (argc2 > 0) {
@@ -237,7 +241,7 @@
 	}
 }
 
-static char *cut_extension __PR(( char * fname ));
+static char *cut_extension(char *fname);
 
 static char *cut_extension(char *fname)
 {
@@ -628,7 +632,7 @@
 
 #include "scsi_cmds.h"
 
-static int RealEnd __PR((SCSI *scgp, UINT4 *buff));
+static int RealEnd(SCSI *scgp, UINT4 *buff);
 
 static int RealEnd(SCSI *scgp, UINT4 *buff)
 {
@@ -850,7 +854,7 @@
 
 #if !defined (HAVE_STRCASECMP) || (HAVE_STRCASECMP != 1)
 #include <ctype.h>
-static int strcasecmp __PR(( const char *s1, const char *s2 ));
+static int strcasecmp(const char *s1, const char *s2);
 static int strcasecmp(const char *s1, const char *s2)
 {
   if (s1 && s2) {
@@ -890,7 +894,7 @@
 
 
 #if !defined (HAVE_STRTOUL) || (HAVE_STRTOUL != 1)
-static unsigned int strtoul __PR(( const char *s1, char **s2, int base ));
+static unsigned int strtoul(const char *s1, char **s2, int base);
 static unsigned int strtoul(const char *s1, char **s2, int base)
 {
 	long retval;
@@ -917,7 +921,7 @@
 
 
 static void
-switch_to_realtime_priority __PR((void));
+switch_to_realtime_priority(void);
 
 #ifdef  HAVE_SYS_PRIOCNTL_H
 
@@ -1033,7 +1037,7 @@
 #endif
 
 /* SCSI cleanup */
-int on_exitscsi __PR((void *status));
+int on_exitscsi(void *status);
 
 int on_exitscsi(void *status)
 {
@@ -1042,7 +1046,7 @@
 }
 
 /* wrapper for signal handler exit needed for Mac-OS-X */
-static void exit_wrapper __PR((int status));
+static void exit_wrapper(int status);
 
 static void exit_wrapper(int status)
 {
@@ -1065,7 +1069,7 @@
 }
 
 /* signal handler for process communication */
-static void set_nonforked __PR((int status));
+static void set_nonforked(int status);
 
 /* ARGSUSED */
 static void set_nonforked(int status)
@@ -1119,7 +1123,7 @@
 }	*para_stat;
 
 
-static void paranoia_reset __PR((void));
+static void paranoia_reset(void);
 static void paranoia_reset()
 {
 	para_stat->c_sector = 0;
@@ -1147,7 +1151,7 @@
 	para_stat->skips = 0;
 }
 
-static void paranoia_callback __PR((long inpos, int function));
+static void paranoia_callback(long inpos, int function);
 
 static void paranoia_callback(long inpos, int function)
 {
@@ -1284,7 +1288,7 @@
 static unsigned minover;
 static unsigned maxover;
 
-static unsigned long calc_SectorBurst __PR((void));
+static unsigned long calc_SectorBurst(void);
 static unsigned long calc_SectorBurst()
 {
 	unsigned long SectorBurstVal;
@@ -1304,7 +1308,7 @@
  */
 #define	PERCENTAGE_PER_TRACK
 
-static int do_read __PR((myringbuff *p, unsigned *total_unsuccessful_retries));
+static int do_read(myringbuff *p, unsigned *total_unsuccessful_retries);
 static int do_read(myringbuff *p, unsigned *total_unsuccessful_retries)
 {
 	unsigned char *newbuf;
@@ -1487,7 +1491,7 @@
 }
 
 static void
-print_percentage __PR((unsigned *poper, int c_offset));
+print_percentage(unsigned *poper, int c_offset);
 
 static void print_percentage(unsigned *poper, int c_offset)
 {
@@ -1521,7 +1525,7 @@
 	fflush(stderr);
 }
 
-static unsigned long do_write __PR((myringbuff *p));
+static unsigned long do_write(myringbuff *p);
 static unsigned long do_write(myringbuff *p)
 {
 	int current_offset;
@@ -1753,7 +1757,7 @@
    }
 
 #if defined HAVE_FORK_AND_SHAREDMEM
-static void forked_read __PR((void));
+static void forked_read(void);
 
 /* This function does all audio cdrom reads
  * until there is nothing more to do
@@ -1782,7 +1786,7 @@
    }
 }
 
-static void forked_write __PR((void));
+static void forked_write(void);
 
 static void forked_write()
 {
@@ -1816,7 +1820,7 @@
  * there is no fork/thread_create system call).
  * This means reads and writes have to wait for each other to complete.
  */
-static void nonforked_loop __PR((void));
+static void nonforked_loop(void);
 
 static void nonforked_loop()
 {
@@ -1839,7 +1843,7 @@
 
 }
 
-void verbose_usage __PR((void));
+void verbose_usage(void);
 
 void verbose_usage()
 {
@@ -1858,7 +1862,7 @@
 }
 
 #ifdef	USE_PARANOIA
-void paranoia_usage __PR((void));
+void paranoia_usage(void);
 
 void paranoia_usage()
 {
@@ -1875,7 +1879,7 @@
 #endif
 
 int
-handle_verbose_opts __PR((char *optstr, long *flagp));
+handle_verbose_opts(char *optstr, long *flagp);
 
 int handle_verbose_opts(char *optstr, long *flagp)
 {
@@ -1944,7 +1948,7 @@
 
 
 int
-handle_paranoia_opts __PR((char *optstr, long *flagp));
+handle_paranoia_opts(char *optstr, long *flagp);
 
 int handle_paranoia_opts(char *optstr, long *flagp)
 {

Modified: nonameyet/branches/cleanup/cdda2wav/cdda2wav.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/cdda2wav.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/cdda2wav.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -45,10 +45,10 @@
 #define LITTLE 0
 #define BIG 1
 
-void FatalError __PR((const char *szMessage, ...));
-void AnalyzeQchannel __PR(( unsigned frame ));
-long SamplesNeeded __PR(( long amount, long undersampling));
-unsigned int get_current_track __PR(( void ));
+void FatalError(const char *szMessage, ...);
+void AnalyzeQchannel(unsigned frame);
+long SamplesNeeded(long amount, long undersampling);
+unsigned int get_current_track(void);
 
 #if defined (sun) && !defined(SVR4)
 #define  atexit(f) on_exit(f, 0)

Modified: nonameyet/branches/cleanup/cdda2wav/interface.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/interface.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/interface.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -99,32 +99,32 @@
 
 int trackindex_disp = 0;
 
-void	priv_init	__PR((void));
-void	priv_on		__PR((void));
-void	priv_off	__PR((void));
+void	priv_init(void);
+void	priv_on(void);
+void	priv_off(void);
 
-void     (*EnableCdda) __PR((SCSI *, int Switch, unsigned uSectorsize));
-unsigned (*doReadToc) __PR(( SCSI *scgp ));
-void	 (*ReadTocText) __PR(( SCSI *scgp ));
-unsigned (*ReadLastAudio) __PR(( SCSI *scgp ));
-int      (*ReadCdRom) __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-int      (*ReadCdRomData) __PR((SCSI *scgp, unsigned char *p, unsigned lSector, unsigned SectorBurstVal ));
-int      (*ReadCdRomSub) __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-subq_chnl *(*ReadSubChannels) __PR(( SCSI *scgp, unsigned lSector ));
-subq_chnl *(*ReadSubQ) __PR(( SCSI *scgp, unsigned char sq_format, unsigned char track ));
-void     (*SelectSpeed) __PR(( SCSI *scgp, unsigned speed ));
-int	(*Play_at) __PR(( SCSI *scgp, unsigned int from_sector, unsigned int sectors));
-int	(*StopPlay) __PR(( SCSI *scgp));
-void	(*trash_cache) __PR((UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+void		(*EnableCdda)(SCSI *, int Switch, unsigned uSectorsize);
+unsigned (*doReadToc)(SCSI *scgp);
+void	 	(*ReadTocText)(SCSI *scgp);
+unsigned (*ReadLastAudio)(SCSI *scgp);
+int      (*ReadCdRom)(SCSI *scgp, UINT4 *p, unsigned lSector, 
+							 unsigned SectorBurstVal);
+int      (*ReadCdRomData)(SCSI *scgp, unsigned char *p, unsigned lSector, 
+								  unsigned SectorBurstVal);
+int      (*ReadCdRomSub)(SCSI *scgp, UINT4 *p, unsigned lSector, 
+								 unsigned SectorBurstVal);
+subq_chnl *(*ReadSubChannels)(SCSI *scgp, unsigned lSector);
+subq_chnl *(*ReadSubQ)(SCSI *scgp, unsigned char sq_format, 
+							  unsigned char track);
+void     (*SelectSpeed)(SCSI *scgp, unsigned speed);
+int		(*Play_at)(SCSI *scgp, unsigned int from_sector, unsigned int sectors);
+int		(*StopPlay)(SCSI *scgp);
+void		(*trash_cache)(UINT4 *p, unsigned lSector, unsigned SectorBurstVal);
 
 #if	defined	USE_PARANOIA
-long cdda_read __PR((void *d, void * buffer, long beginsector, long sectors));
+long cdda_read(void *d, void *buffer, long beginsector, long sectors);
 
-long cdda_read(d, buffer, beginsector, sectors)
-	void *d;
-	void * buffer;
-	long beginsector;
-	long sectors;
+long cdda_read(void *d, void *buffer, long beginsector, long sectors)
 {
 	long ret = ReadCdRom(d, buffer, beginsector, sectors);
 	return ret;
@@ -150,33 +150,35 @@
 
 static int	Is_a_Toshiba3401;
 
-int Toshiba3401 __PR((void));
+int Toshiba3401(void);
 
-int Toshiba3401 ( ) {
+int Toshiba3401() 
+{
   return Is_a_Toshiba3401;
 }
 
 /* hook */
-static void Dummy __PR(( void ));
-static void Dummy ( )
+static void Dummy(void);
+static void Dummy()
 {
 }
 
 static SCSI    *scgp;
 
-SCSI * get_scsi_p __PR((void));
+SCSI *get_scsi_p(void);
 
-SCSI * get_scsi_p( )
+SCSI *get_scsi_p()
 {
     return scgp;
 }
 
 #if !defined(SIM_CD)
 
-static void trash_cache_SCSI __PR((UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+static void trash_cache_SCSI(UINT4 *p, unsigned lSector, 
+									  unsigned SectorBurstVal);
 
-static void
-trash_cache_SCSI(UINT4 *p, unsigned lSector, unsigned SectorBurstVal)
+static void trash_cache_SCSI(UINT4 *p, unsigned lSector, 
+									  unsigned SectorBurstVal)
 {
       /* trash the cache */
       ReadCdRom(get_scsi_p(), p, find_an_off_sector(lSector, SectorBurstVal), min(global.nsectors,6));
@@ -184,12 +186,13 @@
 
 
 
-static void Check_interface_for_device __PR((struct stat *statstruct, char *pdev_name));
-static int OpenCdRom __PR((char *pdev_name));
+static void Check_interface_for_device(struct stat *statstruct, 
+													char *pdev_name);
+static int OpenCdRom(char *pdev_name);
 
-static void SetupSCSI __PR((void));
+static void SetupSCSI(void);
 
-static void SetupSCSI( )
+static void SetupSCSI()
 {
     unsigned char *p;
 
@@ -231,10 +234,10 @@
     /* generic Sony type defaults */
     density = 0x0;
     accepts_fua_bit = -1;
-    EnableCdda = (void (*) __PR((SCSI *, int, unsigned)))Dummy;
+    EnableCdda = (void (*)(SCSI *, int, unsigned))Dummy;
     ReadCdRom = ReadCdda12;
     ReadCdRomSub = ReadCddaSubSony;
-    ReadCdRomData = (int (*) __PR((SCSI *, unsigned char *, unsigned, unsigned ))) ReadStandardData;
+    ReadCdRomData = (int (*)(SCSI *, unsigned char *, unsigned, unsigned))ReadStandardData;
     ReadLastAudio = ReadFirstSessionTOCSony;
     SelectSpeed = SpeedSelectSCSISony;
     Play_at = Play_atSCSI;
@@ -714,9 +717,10 @@
 /* read 'SectorBurst' adjacent sectors of audio sectors 
  * to Buffer '*p' beginning at sector 'lSector'
  */
-static int ReadCdRom_sim __PR(( SCSI *x, UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
-static int 
-ReadCdRom_sim(SCSI *x, UINT4 *p, unsigned lSector, unsigned SectorBurstVal)
+static int ReadCdRom_sim(SCSI *x, UINT4 *p, unsigned lSector, 
+								 unsigned SectorBurstVal);
+static int ReadCdRom_sim(SCSI *x, UINT4 *p, unsigned lSector, 
+								 unsigned SectorBurstVal)
 {
   unsigned int loop=0;
   Int16_t *q = (Int16_t *) p;
@@ -751,7 +755,7 @@
   return SectorBurstVal;
 }
 
-static int Play_at_sim __PR(( SCSI *x, unsigned int from_sector, unsigned int sectors));
+static int Play_at_sim(SCSI *x, unsigned int from_sector, unsigned int sectors);
 static int Play_at_sim(SCSI *x, unsigned int from_sector, unsigned int sectors)
 {
   sim_pos = from_sector*CD_FRAMESAMPLES; 
@@ -762,10 +766,8 @@
 
 
 /* read the table of contents (toc) via the ioctl interface */
-static unsigned ReadToc_sim __PR(( SCSI *x, TOC *toc));
+static unsigned ReadToc_sim(SCSI *x, TOC *toc);
 static unsigned ReadToc_sim(SCSI *x, TOC *toc)
-	SCSI *x;
-	TOC *toc;
 {
     unsigned int scenario;
     int scen[12][3] = { 
@@ -852,12 +854,13 @@
 }
 
 
-static subq_chnl *ReadSubQ_sim __PR(( SCSI *scgp, unsigned char sq_format, unsigned char track ));
+static subq_chnl *ReadSubQ_sim(SCSI *scgp, unsigned char sq_format, 
+										 unsigned char track);
 /* request sub-q-channel information. This function may cause confusion
  * for a drive, when called in the sampling process.
  */
-static subq_chnl *
-ReadSubQ_sim(SCSI *scgp, unsigned char sq_format, unsigned char track)
+static subq_chnl *ReadSubQ_sim(SCSI *scgp, unsigned char sq_format, 
+										 unsigned char track)
 {
     subq_chnl *SQp = (subq_chnl *) (SubQbuffer);
     subq_position *SQPp = (subq_position *) &SQp->data;
@@ -887,26 +890,28 @@
     return (subq_chnl *)(SubQbuffer);
 }
 
-static void SelectSpeed_sim __PR(( SCSI *x, unsigned sp));
+static void SelectSpeed_sim(SCSI *x, unsigned sp);
 /* ARGSUSED */
 static void SelectSpeed_sim(SCSI *x, unsigned sp)
 {
 }
 
-static void trash_cache_sim __PR((UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+static void trash_cache_sim(UINT4 *p, unsigned lSector, 
+									 unsigned SectorBurstVal);
 
 /* ARGSUSED */
-static void trash_cache_sim(UINT4 *p, unsigned lSector, unsigned SectorBurstVal)
+static void trash_cache_sim(UINT4 *p, unsigned lSector, 
+									 unsigned SectorBurstVal)
 {
 }
 
-static void SetupSimCd __PR((void));
+static void SetupSimCd(void);
 
 static void SetupSimCd()
 {
-    EnableCdda = (void (*) __PR((SCSI *, int, unsigned)))Dummy;
+    EnableCdda = (void (*)(SCSI *, int, unsigned))Dummy;
     ReadCdRom = ReadCdRom_sim;
-    ReadCdRomData = (int (*) __PR((SCSI *, unsigned char *, unsigned, unsigned ))) ReadCdRom_sim;
+    ReadCdRomData = (int (*)(SCSI *, unsigned char *, unsigned, unsigned))ReadCdRom_sim;
     doReadToc = ReadToc_sim;
     ReadTocText = NULL;
     ReadSubQ = ReadSubQ_sim;
@@ -914,7 +919,7 @@
     ReadLastAudio = NULL;
     SelectSpeed = SelectSpeed_sim;
     Play_at = Play_at_sim;
-    StopPlay = (int (*) __PR((SCSI *)))Dummy;
+    StopPlay = (int (*)(SCSI *))Dummy;
     trash_cache = trash_cache_sim;
  
 }
@@ -922,7 +927,7 @@
 #endif /* def SIM_CD */
 
 /* perform initialization depending on the interface used. */
-void SetupInterface( )
+void SetupInterface()
 {
 #if	defined SIM_CD
     fprintf( stderr, "SIMULATION MODE !!!!!!!!!!!\n");

Modified: nonameyet/branches/cleanup/cdda2wav/interface.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/interface.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/interface.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -102,30 +102,34 @@
 struct TOC;
 
 /* cdrom access function pointer */
-extern void     (*EnableCdda) __PR((SCSI *scgp, int Switch, unsigned uSectorsize));
-extern unsigned (*doReadToc) __PR(( SCSI *scgp ));
-extern void	(*ReadTocText) __PR(( SCSI *scgp ));
-extern unsigned (*ReadLastAudio) __PR(( SCSI *scgp ));
-extern int      (*ReadCdRom) __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-extern int      (*ReadCdRomSub) __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-extern int      (*ReadCdRomData) __PR((SCSI *scgp, unsigned char *p, unsigned lSector, unsigned SectorBurstVal ));
-extern subq_chnl *(*ReadSubQ) __PR(( SCSI *scgp, unsigned char sq_format, unsigned char track ));
-extern subq_chnl *(*ReadSubChannels) __PR(( SCSI *scgp, unsigned lSector ));
-extern void     (*SelectSpeed) __PR(( SCSI *scgp, unsigned speed ));
-extern int	(*Play_at) __PR(( SCSI *scgp, unsigned from_sector, unsigned sectors));
-extern int	(*StopPlay) __PR(( SCSI *scgp));
-extern void	(*trash_cache) __PR((UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+extern void     (*EnableCdda)(SCSI *scgp, int Switch, unsigned uSectorsize);
+extern unsigned (*doReadToc)(SCSI *scgp);
+extern void	(*ReadTocText)(SCSI *scgp);
+extern unsigned (*ReadLastAudio)(SCSI *scgp);
+extern int      (*ReadCdRom)(SCSI *scgp, UINT4 *p, unsigned lSector, 
+									  unsigned SectorBurstVal);
+extern int      (*ReadCdRomSub)(SCSI *scgp, UINT4 *p, unsigned lSector, 
+										  unsigned SectorBurstVal);
+extern int      (*ReadCdRomData)(SCSI *scgp, unsigned char *p, unsigned lSector,
+											unsigned SectorBurstVal);
+extern subq_chnl *(*ReadSubQ)(SCSI *scgp, unsigned char sq_format, 
+										unsigned char track);
+extern subq_chnl *(*ReadSubChannels)(SCSI *scgp, unsigned lSector);
+extern void     (*SelectSpeed)(SCSI *scgp, unsigned speed);
+extern int	(*Play_at)(SCSI *scgp, unsigned from_sector, unsigned sectors);
+extern int	(*StopPlay)(SCSI *scgp);
+extern void	(*trash_cache)(UINT4 *p, unsigned lSector, unsigned SectorBurstVal);
 
-SCSI    *get_scsi_p __PR(( void ));
+SCSI    *get_scsi_p(void);
 #endif
 
 extern unsigned char *bufferTOC;
 extern subq_chnl *SubQbuffer;
 
 
-void SetupInterface __PR(( void ));
-int	Toshiba3401 __PR(( void ));
+void SetupInterface(void);
+int	Toshiba3401(void);
 
-void	priv_init	__PR((void));
-void	priv_on		__PR((void));
-void	priv_off	__PR((void));
+void	priv_init(void);
+void	priv_on(void);
+void	priv_off(void);

Modified: nonameyet/branches/cleanup/cdda2wav/ioctl.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/ioctl.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/ioctl.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -81,7 +81,7 @@
 
 static int err;
 
-static void EnableCdda_cooked __PR((SCSI *scgp, int fAudioMode, unsigned uSectorsize));
+static void EnableCdda_cooked(SCSI *scgp, int fAudioMode, unsigned uSectorsize);
 /* ARGSUSED */
 static void EnableCdda_cooked(SCSI *scgp, int fAudioMode, unsigned uSectorsize)
 {
@@ -112,7 +112,7 @@
 }
 
 
-static unsigned ReadToc_cooked __PR(( SCSI *x ));
+static unsigned ReadToc_cooked(SCSI *x);
 
 /* read the table of contents (toc) via the ioctl interface */
 static unsigned ReadToc_cooked(SCSI *x)
@@ -211,7 +211,8 @@
     return --tracks;           /* without lead-out */
 }
 
-static void trash_cache_cooked __PR((UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+static void trash_cache_cooked(UINT4 *p, unsigned lSector, 
+										 unsigned SectorBurstVal);
 
 static void trash_cache_cooked(UINT4 *p, unsigned lSector, 
                                unsigned SectorBurstVal)
@@ -255,7 +256,8 @@
 #endif
 }
 
-static void ReadCdRomData_cooked __PR(( SCSI *x, UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+static void ReadCdRomData_cooked(SCSI *x, UINT4 *p, unsigned lSector, 
+											unsigned SectorBurstVal);
 /* read 'SectorBurst' adjacent sectors of data sectors 
  * to Buffer '*p' beginning at sector 'lSector'
  */
@@ -276,7 +278,8 @@
 	return;
 }
 
-static int ReadCdRom_cooked __PR(( SCSI *x, UINT4 *p, unsigned lSector, unsigned SectorBurstVal));
+static int ReadCdRom_cooked(SCSI *x, UINT4 *p, unsigned lSector, 
+									 unsigned SectorBurstVal);
 /* read 'SectorBurst' adjacent sectors of audio sectors 
  * to Buffer '*p' beginning at sector 'lSector'
  */
@@ -368,7 +371,7 @@
   return SectorBurstVal;
 }
 
-static int StopPlay_cooked __PR(( SCSI *x));
+static int StopPlay_cooked(SCSI *x);
 static int StopPlay_cooked(SCSI *x)
 {
     if (x && x->verbose) {
@@ -378,8 +381,9 @@
 	return ioctl( global.cooked_fd, CDROMSTOP, 0 ) ? 0 : -1; 
 }
 
-static int Play_at_cooked __PR(( SCSI *x, unsigned int from_sector, unsigned int sectors));
 static int Play_at_cooked(SCSI *x, unsigned int from_sector, 
+								  unsigned int sectors);
+static int Play_at_cooked(SCSI *x, unsigned int from_sector, 
                           unsigned int sectors)
 {
 	struct cdrom_msf cmsf;
@@ -411,14 +415,11 @@
 	return retval;
 }
 
-#if	defined	PROTOTYPES
-static subq_chnl *ReadSubQ_cooked __PR(( SCSI *x, unsigned char sq_format, unsigned char track ))
-#else
 /* request sub-q-channel information. This function may cause confusion
  * for a drive, when called in the sampling process.
  */
-static subq_chnl *ReadSubQ_cooked(SCSI *x, unsigned char sq_format, unsigned char track)
-#endif
+static subq_chnl *ReadSubQ_cooked(SCSI *x, unsigned char sq_format, 
+											 unsigned char track)
 {
     struct cdrom_subchnl sub_ch;
 
@@ -500,7 +501,7 @@
 }
 
 /* Speed control */
-static void SpeedSelect_cooked __PR(( SCSI *x, unsigned speed));
+static void SpeedSelect_cooked(SCSI *x, unsigned speed);
 /* ARGSUSED */
 static void SpeedSelect_cooked(SCSI *x, unsigned speed)
 {
@@ -568,7 +569,7 @@
 #endif
     EnableCdda = EnableCdda_cooked;
     ReadCdRom = ReadCdRom_cooked;
-    ReadCdRomData = (int (*) __PR((SCSI *, unsigned char *, unsigned, unsigned ))) ReadCdRomData_cooked;
+    ReadCdRomData = (int (*)(SCSI *, unsigned char *, unsigned, unsigned)) ReadCdRomData_cooked;
     doReadToc = ReadToc_cooked;
     ReadTocText = NULL;
     ReadSubQ = ReadSubQ_cooked;

Modified: nonameyet/branches/cleanup/cdda2wav/ioctl.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/ioctl.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/ioctl.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -11,4 +11,4 @@
  */
 
 /* @(#)ioctl.h	1.2 99/12/19 Copyright 1998,1999 Heiko Eissfeldt */
-void SetupCookedIoctl __PR(( char *pdev_name));
+void SetupCookedIoctl(char *pdev_name);

Modified: nonameyet/branches/cleanup/cdda2wav/md5.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/md5.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/md5.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -43,6 +43,6 @@
   unsigned char buffer[64];                         /* input buffer */
 } MD5_CTX;
 
-void MD5Init __PR((MD5_CTX *));
-void MD5Update __PR((MD5_CTX *, unsigned char *, unsigned int));
-void MD5Final __PR((unsigned char [16], MD5_CTX *));
+void MD5Init(MD5_CTX *);
+void MD5Update(MD5_CTX *, unsigned char *, unsigned int);
+void MD5Final(unsigned char [16], MD5_CTX *);

Modified: nonameyet/branches/cleanup/cdda2wav/md5c.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/md5c.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/md5c.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -66,11 +66,11 @@
 
 typedef unsigned char * POINTER;
 
-static void MD5Transform __PR((UINT4 [4], unsigned char [64]));
-static void Encode __PR((unsigned char *, UINT4 *, unsigned int));
-static void Decode __PR((UINT4 *, unsigned char *, unsigned int));
-static void MD5_memcpy __PR((POINTER, POINTER, unsigned int));
-static void MD5_memset __PR((POINTER, int, unsigned int));
+static void MD5Transform(UINT4 [4], unsigned char [64]);
+static void Encode(unsigned char *, UINT4 *, unsigned int);
+static void Decode(UINT4 *, unsigned char *, unsigned int);
+static void MD5_memcpy(POINTER, POINTER, unsigned int);
+static void MD5_memset(POINTER, int, unsigned int);
 
 static unsigned char PADDING[64] = {
   0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,

Modified: nonameyet/branches/cleanup/cdda2wav/raw.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/raw.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/raw.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -20,28 +20,28 @@
 #include <unixstd.h>
 #include "sndfile.h"
 
-static int InitSound __PR(( void ));
+static int InitSound(void);
 
-static int InitSound ( )
+static int InitSound()
 {
   return 0;
 }
 
-static int ExitSound __PR(( void ));
+static int ExitSound(void);
 
-static int ExitSound ( )
+static int ExitSound()
 {
   return 0;
 }
 
-static unsigned long GetHdrSize __PR(( void ));
+static unsigned long GetHdrSize(void);
 
-static unsigned long GetHdrSize( )
+static unsigned long GetHdrSize()
 {
   return 0L;
 }
 
-static unsigned long InSizeToOutSize __PR(( unsigned long BytesToDo ));
+static unsigned long InSizeToOutSize(unsigned long BytesToDo);
 
 static unsigned long InSizeToOutSize(unsigned long BytesToDo)
 {
@@ -50,15 +50,15 @@
 
 struct soundfile rawsound =
 {
-  (int (*) __PR((int audio, long channels,
+  (int (*)(int audio, long channels,
                  unsigned long myrate, long nBitsPerSample,
-                 unsigned long expected_bytes))) InitSound,
+                 unsigned long expected_bytes)) InitSound,
 
-  (int (*) __PR((int audio, unsigned long nBytesDone))) ExitSound,
+  (int (*)(int audio, unsigned long nBytesDone)) ExitSound,
 
   GetHdrSize,
 
-  (int (*) __PR(( int audio, unsigned char *buf, unsigned long BytesToDo ))) write,		/* get sound samples out */
+  (int (*)(int audio, unsigned char *buf, unsigned long BytesToDo)) write,		/* get sound samples out */
 
   InSizeToOutSize,	/* compressed? output file size */
 

Modified: nonameyet/branches/cleanup/cdda2wav/resample.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/resample.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/resample.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -69,20 +69,29 @@
 static long lsum = 0, rsum = 0;	       /* accumulator for left/right channel */
 static long ls2 = 0, rs2 = 0, ls3 = 0, rs3 = 0, auxl = 0, auxr = 0;
 
-static const unsigned char *my_symmemmem	__PR((const unsigned char *HAYSTACK, const size_t HAYSTACK_LEN, const unsigned char *const NEEDLE, const size_t NEEDLE_LEN));
-static const unsigned char *my_memmem	__PR((const unsigned char *HAYSTACK, const size_t HAYSTACK_LEN, const unsigned char *const NEEDLE, const size_t NEEDLE_LEN));
-static const unsigned char *my_memrmem	__PR((const unsigned char *HAYSTACK, const size_t HAYSTACK_LEN, const unsigned char *const NEEDLE, const size_t NEEDLE_LEN));
-static const unsigned char *sync_buffers	__PR((const unsigned char *const newbuf));
-static long interpolate				__PR((long p1, long p2, long p3));
-static void emit_sample				__PR((long lsumval, long rsumval, long channels));
-static void change_endianness			__PR((UINT4 *pSam, unsigned int Samples));
-static void swap_channels			__PR((UINT4 *pSam, unsigned int Samples));
-static int guess_endianess			__PR((UINT4 *p, Int16_t *p2, unsigned int SamplesToDo));
+static const unsigned char *my_symmemmem(const unsigned char *HAYSTACK, 
+													  const size_t HAYSTACK_LEN, 
+													  const unsigned char *const NEEDLE, 
+													  const size_t NEEDLE_LEN);
+static const unsigned char *my_memmem(const unsigned char *HAYSTACK, 
+												  const size_t HAYSTACK_LEN, 
+												  const unsigned char *const NEEDLE, 
+												  const size_t NEEDLE_LEN);
+static const unsigned char *my_memrmem(const unsigned char *HAYSTACK, 
+													const size_t HAYSTACK_LEN, 
+													const unsigned char *const NEEDLE, 
+													const size_t NEEDLE_LEN);
+static const unsigned char *sync_buffers(const unsigned char *const newbuf);
+static long interpolate(long p1, long p2, long p3);
+static void emit_sample(long lsumval, long rsumval, long channels);
+static void change_endianness(UINT4 *pSam, unsigned int Samples);
+static void swap_channels(UINT4 *pSam, unsigned int Samples);
+static int guess_endianess(UINT4 *p, Int16_t *p2, unsigned int SamplesToDo);
 
 
 #ifdef CHECK_MEM
-static void
-check_mem __PR((const unsigned char *p, unsigned long amount, const unsigned char *q, unsigned line, char *file));
+static void check_mem(const unsigned char *p, unsigned long amount, 
+							 const unsigned char *q, unsigned line, char *file);
 
 static void check_mem(const unsigned char *p, unsigned long amount, 
                       const unsigned char *q, unsigned line, char *file)
@@ -472,8 +481,9 @@
 }
 
 #ifdef	ECHO_TO_SOUNDCARD
-static long ReSampleBuffer			__PR((unsigned char *p, unsigned char *newp, long samples, int samplesize));
 static long ReSampleBuffer(unsigned char *p, unsigned char *newp, 
+									long samples, int samplesize);
+static long ReSampleBuffer(unsigned char *p, unsigned char *newp, 
                            long samples, int samplesize)
 {
 	double idx=0.0;

Modified: nonameyet/branches/cleanup/cdda2wav/resample.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/resample.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/resample.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -20,7 +20,7 @@
 extern short samples_to_do;	/* loop variable for conversion */
 extern int Halved;		/* interpolate due to non integral divider */
 extern int jitterShift;		/* track accumulated jitter */
-long SaveBuffer __PR((UINT4 *p,
-                 unsigned long SecsToDo, unsigned long *BytesDone));
-unsigned char *synchronize __PR((UINT4 *p, unsigned SamplesToDo, unsigned TotSamplesDone));
-void	handle_inputendianess __PR((UINT4 *p, unsigned SamplesToDo));
+long SaveBuffer(UINT4 *p, unsigned long SecsToDo, unsigned long *BytesDone);
+unsigned char *synchronize(UINT4 *p, unsigned SamplesToDo, 
+									unsigned TotSamplesDone);
+void	handle_inputendianess(UINT4 *p, unsigned SamplesToDo);

Modified: nonameyet/branches/cleanup/cdda2wav/ringbuff.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/ringbuff.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/ringbuff.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -41,7 +41,7 @@
 #undef _DEBUG
 #include <assert.h>
 
-static void occupy_buffer	__PR((void));
+static void occupy_buffer(void);
 
 myringbuff **he_fill_buffer;
 myringbuff **last_buffer;

Modified: nonameyet/branches/cleanup/cdda2wav/ringbuff.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/ringbuff.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/ringbuff.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -87,11 +87,11 @@
 #define INC(a) (myringbuff *)(((char *)RB_BASE) + (((((char *) (a))-((char *)RB_BASE))/ENTRY_SIZE_PAGE_AL + 1) % total_buffers)*ENTRY_SIZE_PAGE_AL)
 
 
-void set_total_buffers __PR((unsigned int num_buffers, int mysem_id));
-const myringbuff *get_previous_read_buffer __PR((void));
-const myringbuff *get_he_fill_buffer __PR((void));
-myringbuff *get_next_buffer __PR((void));
-myringbuff *get_oldest_buffer __PR((void));
-void define_buffer __PR((void));
-void drop_buffer __PR((void));
-void drop_all_buffers __PR((void));
+void set_total_buffers(unsigned int num_buffers, int mysem_id);
+const myringbuff *get_previous_read_buffer(void);
+const myringbuff *get_he_fill_buffer(void);
+myringbuff *get_next_buffer(void);
+myringbuff *get_oldest_buffer(void);
+void define_buffer(void);
+void drop_buffer(void);
+void drop_all_buffers(void);

Modified: nonameyet/branches/cleanup/cdda2wav/scsi_cmds.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/scsi_cmds.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/scsi_cmds.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -57,8 +57,8 @@
 subq_chnl *SubQbuffer;
 unsigned char *cmd;
 
-static unsigned ReadFullTOCSony __PR(( SCSI *scgp ));
-static unsigned ReadFullTOCMMC __PR(( SCSI *scgp ));
+static unsigned ReadFullTOCSony(SCSI *scgp);
+static unsigned ReadFullTOCMMC(SCSI *scgp);
 
 
 int SCSI_emulated_ATAPI_on(SCSI *scgp)
@@ -358,7 +358,7 @@
 };
 
 #ifdef	WARN_FULLTOC
-static unsigned lba __PR((struct msf_address *ad));
+static unsigned lba(struct msf_address *ad);
 
 static unsigned lba(struct msf_address *ad)
 {
@@ -366,7 +366,7 @@
 }
 #endif
 
-static unsigned dvd_lba __PR((struct zmsf_address *ad));
+static unsigned dvd_lba(struct zmsf_address *ad);
 
 static unsigned dvd_lba(struct zmsf_address *ad)
 {
@@ -392,7 +392,8 @@
 
 static unsigned long first_session_leadout = 0;
 
-static unsigned collect_tracks __PR((struct outer *po, unsigned entries, BOOL bcd_flag));
+static unsigned collect_tracks(struct outer *po, unsigned entries, 
+										 BOOL bcd_flag);
 
 static unsigned collect_tracks(struct outer *po, unsigned entries, 
                                BOOL bcd_flag)
@@ -958,11 +959,11 @@
 
 /* Read max. SectorBurst of cdda sectors to buffer
    via standard SCSI-2 Read(10) command */
-static int ReadStandardLowlevel __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal, unsigned secsize ));
+static int ReadStandardLowlevel(SCSI *scgp, UINT4 *p, unsigned lSector, 
+										  unsigned SectorBurstVal, unsigned secsize);
 
-static int 
-ReadStandardLowlevel(SCSI *scgp, UINT4 *p, unsigned lSector, 
-                     unsigned SectorBurstVal, unsigned secsize)
+static int ReadStandardLowlevel(SCSI *scgp, UINT4 *p, unsigned lSector, 
+										  unsigned SectorBurstVal, unsigned secsize)
 {
   /* READ10, flags, block1 msb, block2, block3, block4 lsb, reserved, 
      transfer len msb, transfer len lsb, block addressing mode */
@@ -1254,7 +1255,7 @@
 
 static subq_chnl sc;
 
-static subq_chnl* fill_subchannel __PR((unsigned char bufferwithQ[]));
+static subq_chnl* fill_subchannel(unsigned char bufferwithQ[]);
 static subq_chnl* fill_subchannel(unsigned char bufferwithQ[])
 {
 	sc.subq_length = 0;
@@ -1292,7 +1293,8 @@
 	return scg_getresid(scgp) != 0;
 }
 
-int ReadCddaSub96Sony __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
+int ReadCddaSub96Sony(SCSI *scgp, UINT4 *p, unsigned lSector, 
+							 unsigned SectorBurstVal);
 
 int ReadCddaSub96Sony(SCSI *scgp, UINT4 *p, unsigned lSector, 
                       unsigned SectorBurstVal)
@@ -1362,7 +1364,7 @@
 	return scg_getresid(scgp) != 0;
 }
 
-static subq_chnl *ReadSubChannelsMMC __PR((SCSI *scgp, unsigned lSector));
+static subq_chnl *ReadSubChannelsMMC(SCSI *scgp, unsigned lSector);
 static subq_chnl *ReadSubChannelsMMC(SCSI *scgp, unsigned lSector)
 {
 	int retval = ReadCddaSubMMC12(scgp, (UINT4 *)bufferTOC, lSector, 1);
@@ -1707,7 +1709,7 @@
 
 static caddr_t scsibuffer;	/* page aligned scsi transfer buffer */
 
-void init_scsibuf __PR((SCSI *, unsigned));
+void init_scsibuf(SCSI *scsp, unsigned amt);
 
 void init_scsibuf(SCSI *scgp, unsigned amt)
 {

Modified: nonameyet/branches/cleanup/cdda2wav/scsi_cmds.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/scsi_cmds.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/scsi_cmds.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -15,45 +15,54 @@
 
 extern unsigned char *cmd;
 struct TOC;
-int SCSI_emulated_ATAPI_on __PR(( SCSI *scgp ));
-unsigned char *Inquiry __PR(( SCSI *scgp ));
-int TestForMedium __PR(( SCSI *scgp ));
-void SpeedSelectSCSIMMC __PR((SCSI *scgp, unsigned speed));
-void SpeedSelectSCSIYamaha __PR((SCSI *scgp, unsigned speed));
-void SpeedSelectSCSISony __PR((SCSI *scgp, unsigned speed));
-void SpeedSelectSCSIPhilipsCDD2600 __PR((SCSI *scgp, unsigned speed));
-void SpeedSelectSCSINEC __PR((SCSI *scgp, unsigned speed));
-void SpeedSelectSCSIToshiba __PR((SCSI *scgp, unsigned speed));
-subq_chnl *ReadSubQSCSI __PR(( SCSI *scgp, unsigned char sq_format, unsigned char ltrack));
-subq_chnl *ReadSubChannelsSony __PR((SCSI *scgp, unsigned lSector ));
-subq_chnl *ReadSubChannelsFallbackMMC __PR((SCSI *scgp, unsigned lSector ));
-subq_chnl *ReadStandardSub __PR((SCSI *scgp, unsigned lSector ));
-int ReadCddaMMC12 __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-int ReadCdda12Matsushita __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-int ReadCdda12 __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SecorBurstVal ));
-int ReadCdda10 __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SecorBurstVal ));
-int ReadStandard __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SctorBurstVal ));
-int ReadStandardData __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SctorBurstVal ));
-int ReadCddaFallbackMMC __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SctorBurstVal ));
-int ReadCddaSubSony __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-int ReadCddaSub96Sony __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-int ReadCddaSubMMC12 __PR((SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SectorBurstVal ));
-unsigned ReadTocSony __PR(( SCSI *scgp ));
-unsigned ReadTocMMC __PR(( SCSI *scgp ));
-unsigned ReadTocSCSI __PR(( SCSI *scgp ));
-unsigned ReadFirstSessionTOCSony __PR(( SCSI *scgp ));
-unsigned ReadFirstSessionTOCMMC __PR(( SCSI *scgp ));
-void ReadTocTextSCSIMMC __PR(( SCSI *scgp ));
-int Play_atSCSI __PR(( SCSI *scgp, unsigned int from_sector, unsigned int sectors));
-int StopPlaySCSI __PR(( SCSI *scgp ));
-void EnableCddaModeSelect __PR((SCSI *scgp, int fAudioMode, unsigned uSectorsize));
-int set_sectorsize __PR((SCSI *scgp, unsigned int secsize));
+int SCSI_emulated_ATAPI_on(SCSI *scgp);
+unsigned char *Inquiry(SCSI *scgp);
+int TestForMedium(SCSI *scgp);
+void SpeedSelectSCSIMMC(SCSI *scgp, unsigned speed);
+void SpeedSelectSCSIYamaha(SCSI *scgp, unsigned speed);
+void SpeedSelectSCSISony(SCSI *scgp, unsigned speed);
+void SpeedSelectSCSIPhilipsCDD2600(SCSI *scgp, unsigned speed);
+void SpeedSelectSCSINEC(SCSI *scgp, unsigned speed);
+void SpeedSelectSCSIToshiba(SCSI *scgp, unsigned speed);
+subq_chnl *ReadSubQSCSI(SCSI *scgp, unsigned char sq_format, 
+								unsigned char ltrack);
+subq_chnl *ReadSubChannelsSony(SCSI *scgp, unsigned lSector);
+subq_chnl *ReadSubChannelsFallbackMMC(SCSI *scgp, unsigned lSector);
+subq_chnl *ReadStandardSub(SCSI *scgp, unsigned lSector);
+int ReadCddaMMC12(SCSI *scgp, UINT4 *p, unsigned lSector, 
+						unsigned SectorBurstVal);
+int ReadCdda12Matsushita(SCSI *scgp, UINT4 *p, unsigned lSector, 
+								 unsigned SectorBurstVal);
+int ReadCdda12(SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SecorBurstVal);
+int ReadCdda10(SCSI *scgp, UINT4 *p, unsigned lSector, unsigned SecorBurstVal);
+int ReadStandard(SCSI *scgp, UINT4 *p, unsigned lSector, 
+					  unsigned SctorBurstVal);
+int ReadStandardData(SCSI *scgp, UINT4 *p, unsigned lSector, 
+							unsigned SctorBurstVal);
+int ReadCddaFallbackMMC(SCSI *scgp, UINT4 *p, unsigned lSector, 
+								unsigned SctorBurstVal);
+int ReadCddaSubSony(SCSI *scgp, UINT4 *p, unsigned lSector, 
+						  unsigned SectorBurstVal);
+int ReadCddaSub96Sony(SCSI *scgp, UINT4 *p, unsigned lSector, 
+							 unsigned SectorBurstVal);
+int ReadCddaSubMMC12(SCSI *scgp, UINT4 *p, unsigned lSector, 
+							unsigned SectorBurstVal);
+unsigned ReadTocSony(SCSI *scgp);
+unsigned ReadTocMMC(SCSI *scgp);
+unsigned ReadTocSCSI(SCSI *scgp);
+unsigned ReadFirstSessionTOCSony(SCSI *scgp);
+unsigned ReadFirstSessionTOCMMC(SCSI *scgp);
+void ReadTocTextSCSIMMC(SCSI *scgp);
+int Play_atSCSI(SCSI *scgp, unsigned int from_sector, unsigned int sectors);
+int StopPlaySCSI(SCSI *scgp);
+void EnableCddaModeSelect(SCSI *scgp, int fAudioMode, unsigned uSectorsize);
+int set_sectorsize(SCSI *scgp, unsigned int secsize);
 unsigned int
-get_orig_sectorsize __PR((SCSI *scgp, unsigned char *m4, unsigned char *m10,
-                    unsigned char *m11));
-int heiko_mmc __PR(( SCSI *scgp ));
-void init_scsibuf __PR(( SCSI *scgp, unsigned amt ));
-int	myscsierr __PR(( SCSI *scgp ));
+get_orig_sectorsize(SCSI *scgp, unsigned char *m4, unsigned char *m10,
+                    unsigned char *m11);
+int heiko_mmc(SCSI *scgp);
+void init_scsibuf(SCSI *scgp, unsigned amt);
+int	myscsierr(SCSI *scgp);
 
 extern int accepts_fua_bit;
 extern unsigned char density;

Modified: nonameyet/branches/cleanup/cdda2wav/semshm.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/semshm.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/semshm.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -102,7 +102,7 @@
 char *end_of_shm;
 #endif
 
-int flush_buffers __PR((void));
+int flush_buffers(void);
 
 
 /*------ Semaphore interfacing (for special cases only) ----------*/
@@ -111,7 +111,7 @@
 #if defined(HAVE_SEMGET) && defined(USE_SEMAPHORES)
 
 int sem_id;
-static int seminstall	__PR((key_t key, int amount));
+static int seminstall(key_t key, int amount);
 
 static int seminstall(key_t key, int amount)
 {
@@ -274,7 +274,7 @@
 
 
 #if defined(HAVE_SHMAT) && (HAVE_SHMAT == 1)
-static int shm_request_nommap	__PR((int size, unsigned char **memptr));
+static int shm_request_nommap(int size, unsigned char **memptr);
 
 /* request a shared memory block */
 static int shm_request_nommap(int size, unsigned char **memptr)
@@ -330,7 +330,7 @@
 #endif	/* #if defined(HAVE_SHMAT) && (HAVE_SHMAT == 1) */
 
 
-static int shm_request	__PR((int size, unsigned char **memptr));
+static int shm_request(int size, unsigned char **memptr);
 
 #ifdef  USE_USGSHM
 /* request a shared memory block */
@@ -341,7 +341,7 @@
 #endif
 
 /* release semaphores */
-void free_sem __PR(( void ));
+void free_sem(void);
 void free_sem()
 {
 #if defined(HAVE_SEMGET) && defined(USE_SEMAPHORES)

Modified: nonameyet/branches/cleanup/cdda2wav/semshm.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/semshm.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/semshm.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -24,9 +24,9 @@
 extern int sem_id;
 #else
 #define sem_id 42	/* nearly any other number would do it too */
-void init_pipes __PR((void));
-void init_parent __PR((void));
-void init_child __PR((void));
+void init_pipes(void);
+void init_parent(void);
+void init_child(void);
 #endif
 
 
@@ -35,9 +35,9 @@
 #define	AREA_NAME	"shmfifo"
 #endif
 
-void free_sem __PR((void));
-int semrequest __PR((int semid, int semnum));
-int semrelease __PR((int semid, int semnum, int amount));
-int flush_buffers __PR((void));
-void * request_shm_sem __PR((unsigned amount_of_sh_mem, unsigned char **pointer));
+void free_sem(void);
+int semrequest(int semid, int semnum);
+int semrelease(int semid, int semnum, int amount);
+int flush_buffers(void);
+void * request_shm_sem(unsigned amount_of_sh_mem, unsigned char **pointer);
 

Modified: nonameyet/branches/cleanup/cdda2wav/setuid.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/setuid.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/setuid.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -81,8 +81,8 @@
 
 #if defined _POSIX_SAVED_IDS && defined (HAVE_SETEUID) && defined SCO
 /* SCO seems to lack the prototypes... */
-int	seteuid __PR((uid_t euid));
-int	setegid __PR((gid_t guid));
+int	seteuid(uid_t euid);
+int	setegid(gid_t guid);
 #endif
 
 void needroot(int necessary)

Modified: nonameyet/branches/cleanup/cdda2wav/setuid.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/setuid.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/setuid.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -12,20 +12,20 @@
 
 /* @(#)setuid.h	1.2 99/12/19 Copyright 1998,1999 Heiko Eissfeldt */
 /* Security functions */
-void initsecurity __PR((void));
+void initsecurity(void);
 
-void needroot __PR((int necessary));
-void dontneedroot __PR((void));
-void neverneedroot __PR((void));
+void needroot(int necessary);
+void dontneedroot(void);
+void neverneedroot(void);
 
-void needgroup __PR((int necessary));
-void dontneedgroup __PR((void));
-void neverneedgroup __PR((void));
+void needgroup(int necessary);
+void dontneedgroup(void);
+void neverneedgroup(void);
 
 #if defined (HPUX)
 #define HAVE_SETREUID
 #define HAVE_SETREGID
-int seteuid __PR((uid_t uid));
-int setreuid __PR((uid_t uid1, uid_t uid2));
-int setregid __PR((gid_t gid1, gid_t gid2));
+int seteuid(uid_t uid);
+int setreuid(uid_t uid1, uid_t uid2);
+int setregid(gid_t gid1, gid_t gid2);
 #endif

Modified: nonameyet/branches/cleanup/cdda2wav/sha.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/sha.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/sha.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -57,9 +57,9 @@
     int local;			/* unprocessed amount in data */
 } SHA_INFO;
 
-void sha_init __PR((SHA_INFO *));
-void sha_update __PR((SHA_INFO *, BYTE *, int));
-void sha_final __PR((unsigned char [20], SHA_INFO *));
+void sha_init(SHA_INFO *);
+void sha_update(SHA_INFO *, BYTE *, int);
+void sha_final(unsigned char [20], SHA_INFO *);
 
 #ifdef SHA_FOR_C
 
@@ -67,9 +67,9 @@
 #include <stdxlib.h>
 #include <stdio.h>
 
-void sha_stream __PR((unsigned char [20], SHA_INFO *, FILE *));
-void sha_print __PR((unsigned char [20]));
-char *sha_version __PR((void));
+void sha_stream(unsigned char [20], SHA_INFO *, FILE *);
+void sha_print(unsigned char [20]);
+char *sha_version(void);
 #endif /* SHA_FOR_C */
 
 #define SHA_VERSION 1

Modified: nonameyet/branches/cleanup/cdda2wav/sha_func.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/sha_func.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/sha_func.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -108,7 +108,7 @@
 
 /* do SHA transformation */
 
-static void sha_transform __PR((SHA_INFO *sha_info));
+static void sha_transform(SHA_INFO *sha_info);
 
 static void sha_transform(SHA_INFO *sha_info)
 {
@@ -224,7 +224,7 @@
 
 /* initialize the SHA digest */
 
-void sha_init __PR((SHA_INFO *sha_info));
+void sha_init(SHA_INFO *sha_info);
 
 void sha_init(SHA_INFO *sha_info)
 {
@@ -240,7 +240,7 @@
 
 /* update the SHA digest */
 
-void sha_update __PR((SHA_INFO *sha_info, BYTE *buffer, int count));
+void sha_update(SHA_INFO *sha_info, BYTE *buffer, int count);
 
 void sha_update(SHA_INFO *sha_info, BYTE *buffer, int count)
 {
@@ -280,7 +280,7 @@
 
 /* finish computing the SHA digest */
 
-void sha_final __PR((unsigned char digest[20], SHA_INFO *sha_info));
+void sha_final(unsigned char digest[20], SHA_INFO *sha_info);
 
 void sha_final(unsigned char digest[20], SHA_INFO *sha_info)
 {
@@ -336,7 +336,7 @@
 
 #define BLOCK_SIZE	8192
 
-void sha_stream __PR((unsigned char digest[20], SHA_INFO *sha_info, FILE *fin));
+void sha_stream(unsigned char digest[20], SHA_INFO *sha_info, FILE *fin);
 
 void sha_stream(unsigned char digest[20], SHA_INFO *sha_info, FILE *fin)
 {
@@ -352,7 +352,7 @@
 
 /* print a SHA digest */
 
-void sha_print __PR((unsigned char digest[20]));
+void sha_print(unsigned char digest[20]);
 
 void sha_print(unsigned char digest[20])
 {
@@ -366,7 +366,7 @@
     }
 }
 
-char *sha_version __PR((void));
+char *sha_version(void);
 
 char *sha_version()
 {

Modified: nonameyet/branches/cleanup/cdda2wav/sndconfig.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/sndconfig.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/sndconfig.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -96,7 +96,7 @@
 static WAVEHDR	wavehdr[WAVEHDRS];
 static unsigned lastwav = 0;
 
-static int check_winsound_caps __PR((int bits, double rate, int channels));
+static int check_winsound_caps(int bits, double rate, int channels);
 
 static int check_winsound_caps(int bits, double rate, int channels)
 {
@@ -462,7 +462,7 @@
   return 0;
 }
 
-int open_snd_device ()
+int open_snd_device()
 {
 #if	defined(F_GETFL) && defined(F_SETFL) && defined(O_NONBLOCK)
 	int	fl;

Modified: nonameyet/branches/cleanup/cdda2wav/sndconfig.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/sndconfig.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/sndconfig.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -12,9 +12,9 @@
 
 /* @(#)sndconfig.h	1.2 99/12/19 Copyright 1998,1999 Heiko Eissfeldt */
 #define NONBLOCKING_AUDIO
-int set_snd_device __PR((const char *devicename));
-int init_soundcard __PR((double rate, int bits));
+int set_snd_device(const char *devicename);
+int init_soundcard(double rate, int bits);
 
-int open_snd_device __PR((void));
-int close_snd_device __PR((void));
-int write_snd_device __PR((char *buffer, unsigned length));
+int open_snd_device(void);
+int close_snd_device(void);
+int write_snd_device(char *buffer, unsigned length);

Modified: nonameyet/branches/cleanup/cdda2wav/sndfile.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/sndfile.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/sndfile.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -22,15 +22,13 @@
 #include <utypes.h>
 
 struct soundfile {
-	int	(* InitSound)		__PR((int audio, long channels,
-						Ulong rate,
-						long nBitsPerSample,
-						Ulong expected_bytes));
-	int	(* ExitSound)		__PR((int audio, Ulong nBytesDone));
-	Ulong	(* GetHdrSize)		__PR((void));
-	int	(* WriteSound)		__PR((int audio, unsigned char *buf,
-						Ulong BytesToDo));
-	Ulong	(* InSizeToOutSize)	__PR((Ulong BytesToDo));
+	int	(* InitSound)(int audio, long channels, Ulong rate,
+							  long nBitsPerSample,
+							  Ulong expected_bytes);
+	int	(* ExitSound)(int audio, Ulong nBytesDone);
+	Ulong	(* GetHdrSize)(void);
+	int	(* WriteSound)(int audio, unsigned char *buf, Ulong BytesToDo);
+	Ulong	(* InSizeToOutSize)(Ulong BytesToDo);
 
 	int	need_big_endian;
 };

Modified: nonameyet/branches/cleanup/cdda2wav/sun.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/sun.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/sun.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -45,11 +45,11 @@
 
 static SUNHDR sunHdr;
 
-static int InitSound __PR(( int audio, long channels, unsigned long rate, long nBitsPerSample, unsigned long expected_bytes ));
+static int InitSound(int audio, long channels, unsigned long rate, 
+							long nBitsPerSample, unsigned long expected_bytes);
 
-static int 
-InitSound(int audio, long channels, unsigned long rate, long nBitsPerSample, 
-          unsigned long expected_bytes)
+static int InitSound(int audio, long channels, unsigned long rate, 
+							long nBitsPerSample, unsigned long expected_bytes)
 {
   unsigned long format = nBitsPerSample > 8 ? 0x03 : 0x02;
 
@@ -63,7 +63,7 @@
   return write (audio, &sunHdr, sizeof (sunHdr));
 }
 
-static int ExitSound __PR(( int audio, unsigned long nBytesDone ));
+static int ExitSound(int audio, unsigned long nBytesDone);
 
 static int ExitSound(int audio, unsigned long nBytesDone)
 {
@@ -76,14 +76,14 @@
   return write (audio, &sunHdr, sizeof (sunHdr));
 }
 
-static unsigned long GetHdrSize __PR(( void ));
+static unsigned long GetHdrSize(void);
 
-static unsigned long GetHdrSize( )
+static unsigned long GetHdrSize()
 {
   return sizeof( sunHdr );
 }
 
-static unsigned long InSizeToOutSize __PR(( unsigned long BytesToDo ));
+static unsigned long InSizeToOutSize(unsigned long BytesToDo);
 
 static unsigned long InSizeToOutSize(unsigned long BytesToDo)
 {
@@ -95,7 +95,10 @@
 	InitSound,		/* init header method */
 	ExitSound,		/* exit header method */
 	GetHdrSize,		/* report header size method */
-	(int (*) __PR(( int audio, unsigned char *buf, unsigned long BytesToDo ))) write,			/* get sound samples out */
+	/* get sound samples out */
+	(int (*)(int audio, unsigned char *buf, unsigned long BytesToDo)) write,
 	InSizeToOutSize,	/* compressed? output file size */
 	1			/* needs big endian samples */
 };
+
+

Modified: nonameyet/branches/cleanup/cdda2wav/toc.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/toc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/toc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -72,11 +72,11 @@
 #include "exitcodes.h"
 #include "ringbuff.h"
 
-int Get_Mins __PR(( unsigned long p_track ));
-int Get_Secs __PR(( unsigned long p_track ));
-int Get_Frames __PR(( unsigned long p_track ));
-int Get_Flags __PR(( unsigned long p_track ));
-int Get_SCMS __PR(( unsigned long p_track ));
+int Get_Mins(unsigned long p_track);
+int Get_Secs(unsigned long p_track);
+int Get_Frames(unsigned long p_track);
+int Get_Flags(unsigned long p_track);
+int Get_SCMS(unsigned long p_track);
 
 
 #if	defined	USE_REMOTE
@@ -102,25 +102,21 @@
 
 struct iterator;
 
-static void UpdateTrackData	__PR((int p_num));
-static void UpdateIndexData	__PR((int p_num));
-static void UpdateTimeData	__PR((int p_min, int p_sec, int p_frm));
-static unsigned int is_multisession	__PR(( void ));
-static unsigned int get_end_of_last_audio_track	__PR((unsigned mult_off));
-static int cddb_sum		__PR((int n));
-static void dump_extra_info	__PR((unsigned from));
-static int GetIndexOfSector	__PR((unsigned sec, unsigned track));
-static int patch_cd_extra	__PR((unsigned track, unsigned long sector));
-static void patch_to_audio	__PR((unsigned long p_track));
-static int restrict_tracks_illleadout __PR(( void ));
+static void 			UpdateTrackData(int p_num);
+static void 			UpdateIndexData(int p_num);
+static void 			UpdateTimeData(int p_min, int p_sec, int p_frm);
+static unsigned int 	is_multisession(void);
+static unsigned int 	get_end_of_last_audio_track(unsigned mult_off);
+static int 				cddb_sum(int n);
+static void 			dump_extra_info(unsigned from);
+static int 				GetIndexOfSector(unsigned sec, unsigned track);
+static int 				patch_cd_extra(unsigned track, unsigned long sector);
+static void 			patch_to_audio(unsigned long p_track);
+static int 				restrict_tracks_illleadout(void);
+static void 			Set_MCN(unsigned char *MCN_arg);
+static void 			Set_ISRC(int track, const unsigned char *ISRC_arg);
+static void 			InitIterator(struct iterator *iter, unsigned long p_track);
 
-static void Set_MCN		__PR(( unsigned char *MCN_arg ));
-static void Set_ISRC		__PR(( int track, const unsigned char *ISRC_arg ));
-
-
-
-static void InitIterator __PR(( struct iterator *iter, unsigned long p_track ));
-
 static unsigned char g_track=0xff, g_index=0xff;	/* current track, index */
 
 /* Conversion function: from logical block adresses  to minute,second,frame
@@ -227,7 +223,7 @@
     return retval;
 }
 
-static int can_read_illleadout __PR((void));
+static int can_read_illleadout(void);
 
 static int can_read_illleadout()
 {
@@ -244,8 +240,7 @@
 }
 
 
-unsigned
-find_an_off_sector __PR((unsigned lSector, unsigned SectorBurstVal));
+unsigned find_an_off_sector(unsigned lSector, unsigned SectorBurstVal);
 
 unsigned find_an_off_sector(unsigned lSector, unsigned SectorBurstVal)
 {
@@ -265,7 +260,7 @@
 #endif
 
 
-int handle_cdtext __PR(( void ));
+int handle_cdtext(void);
 
 int handle_cdtext()
 {
@@ -382,14 +377,14 @@
    }
 }
 
-static void dump_cdtext_info __PR((void));
+static void dump_cdtext_info(void);
 
 #if defined CDDB_SUPPORT
-static void emit_cddb_form	__PR((char *fname_baseval));
+static void emit_cddb_form(char *fname_baseval);
 #endif
 
 #if defined CDINDEX_SUPPORT
-static void emit_cdindex_form	__PR((char *fname_baseval));
+static void emit_cdindex_form(char *fname_baseval);
 #endif
 
 
@@ -444,9 +439,9 @@
 struct iterator {
 	int index;
 	int startindex;
-	void        (*reset)        __PR(( struct iterator *this ));
-	struct TOC *(*getNextTrack) __PR(( struct iterator *this ));
-	int         (*hasNextTrack) __PR(( struct iterator *this ));
+	void        (*reset)(struct iterator *this);
+	struct TOC *(*getNextTrack)(struct iterator *this);
+	int         (*hasNextTrack)(struct iterator *this);
 };
 
 
@@ -819,8 +814,8 @@
 #if	defined	USE_REMOTE
 #include <pwd.h>
 
-int readn __PR((register int fd, register char *ptr, register int nbytes));
-int writen __PR((register int fd, register char *ptr, register int nbytes));
+int readn(register int fd, register char *ptr, register int nbytes);
+int writen(register int fd, register char *ptr, register int nbytes);
 
 int readn(register int fd, register char *ptr, register int nbytes)
 {
@@ -864,10 +859,8 @@
 
 #define	SOCKBUFF	2048
 
-int
-process_cddb_titles __PR((int sock_fd, char *inbuff, int readbytes));
-int
-process_cddb_titles(int sock_fd, char *inbuff, int readbytes)
+int process_cddb_titles(int sock_fd, char *inbuff, int readbytes);
+int process_cddb_titles(int sock_fd, char *inbuff, int readbytes)
 {
 	int	finished = 0;
 	char	*p = inbuff;
@@ -1020,7 +1013,7 @@
 	return finished;
 }
 
-static int handle_userchoice __PR((char *p, unsigned size));
+static int handle_userchoice(char *p, unsigned size);
 
 static int handle_userchoice(char *p, unsigned size)
 {
@@ -1435,7 +1428,7 @@
 
 #if	defined CDINDEX_SUPPORT
 
-static int IsSingleArtist __PR((void));
+static int IsSingleArtist(void);
 
 /* check, if there are more than one track creators */
 static int IsSingleArtist()
@@ -1525,8 +1518,7 @@
 "&yuml;",
 };
 
-static char *
-ascii2html __PR((unsigned char *inp));
+static char *ascii2html(unsigned char *inp);
 
 static char *ascii2html(unsigned char *inp)
 {
@@ -1780,7 +1772,7 @@
 #endif
 }
 
-static char *quote __PR((unsigned char *string));
+static char *quote(unsigned char *string);
 
 static char *quote(unsigned char *string)
 {
@@ -1800,7 +1792,7 @@
 
 
 
-static void DisplayToc_with_gui __PR(( unsigned long dw ));
+static void DisplayToc_with_gui(unsigned long dw);
 
 static void DisplayToc_with_gui(unsigned long dw)
 {
@@ -1970,7 +1962,7 @@
 	} /* if */
 }
 
-static void DisplayToc_no_gui __PR(( unsigned long dw ));
+static void DisplayToc_no_gui(unsigned long dw);
 
 static void DisplayToc_no_gui(unsigned long dw)
 {
@@ -2287,7 +2279,7 @@
 	}
 }
 
-static void Read_MCN_toshiba __PR(( subq_chnl **sub_ch ));
+static void Read_MCN_toshiba(subq_chnl **sub_ch);
 
 static void Read_MCN_toshiba(subq_chnl **sub_ch)
 {
@@ -2314,7 +2306,7 @@
 	}
 }
 
-static void Get_Set_MCN __PR(( void ));
+static void Get_Set_MCN(void);
 
 static void Get_Set_MCN()
 {
@@ -2389,7 +2381,7 @@
 }
 
 
-static void Read_ISRC_toshiba __PR(( subq_chnl **sub_ch, unsigned tr ));
+static void Read_ISRC_toshiba(subq_chnl **sub_ch, unsigned tr);
 
 static void Read_ISRC_toshiba(subq_chnl **sub_ch, unsigned tr)
 {
@@ -2412,7 +2404,7 @@
 }
 
 
-static void Get_Set_ISRC __PR(( unsigned tr ));
+static void Get_Set_ISRC(unsigned tr);
 
 static void Get_Set_ISRC(unsigned tr)
 {
@@ -2663,7 +2655,7 @@
 
 static int playing = 0;
 
-static subq_chnl *ReadSubChannel __PR((unsigned sec));
+static subq_chnl *ReadSubChannel(unsigned sec);
 
 static subq_chnl *ReadSubChannel(unsigned sec)
 {
@@ -2735,7 +2727,7 @@
 	return sub_ch;
 }
 
-static int ReadSubControl __PR((unsigned sec));
+static int ReadSubControl(unsigned sec);
 static int ReadSubControl(unsigned sec)
 {
 	subq_chnl *sub_ch = ReadSubChannel(sec);
@@ -2744,7 +2736,7 @@
 	return	sub_ch->control_adr & 0xf0;
 }
 
-static int HaveSCMS __PR((unsigned StartSector));
+static int HaveSCMS(unsigned StartSector);
 static int HaveSCMS(unsigned StartSector)
 {
 	int i;
@@ -2847,11 +2839,11 @@
     return sub_ch ? sub_ch->index == 244 ? 1 : sub_ch->index : -1;
 }
 
-static int
-ScanBackwardFrom __PR((unsigned sec, unsigned limit, int *where, unsigned track));
+static int ScanBackwardFrom(unsigned sec, unsigned limit, int *where, 
+									 unsigned track);
 
-static int 
-ScanBackwardFrom(unsigned sec, unsigned limit, int *where, unsigned track)
+static int ScanBackwardFrom(unsigned sec, unsigned limit, int *where, 
+									 unsigned track)
 {
 	unsigned lastindex = 0;
 	unsigned mysec = sec;
@@ -2917,9 +2909,11 @@
 }
 
 #ifdef	USE_LINEAR_SEARCH
-static int linear_search	__PR((int searchInd, unsigned int Start, unsigned int End, unsigned track));
-static int 
-linear_search(int searchInd, unsigned Start, unsigned End, unsigned track)
+static int linear_search(int searchInd, unsigned int Start, unsigned int End, 
+								 unsigned track);
+
+static int linear_search(int searchInd, unsigned int Start, unsigned int End, 
+								 unsigned track)
 {
       int l = Start;
       int r = End;
@@ -2943,9 +2937,11 @@
 
 #ifndef	USE_LINEAR_SEARCH
 #undef DEBUG_BINSEARCH
-static int binary_search	__PR((int searchInd, unsigned int Start, unsigned int End, unsigned track));
-static int 
-binary_search(int searchInd, unsigned Start, unsigned End, unsigned track)
+static int binary_search(int searchInd, unsigned int Start, unsigned int End, 
+								 unsigned track);
+
+static int binary_search(int searchInd, unsigned Start, unsigned End, 
+								 unsigned track)
 {
       int l = Start;
       int r = End;
@@ -2997,11 +2993,11 @@
 #endif
 
 
-static void
-register_index_position __PR((int IndexOffset, index_list **last_index_entry));
+static void register_index_position(int IndexOffset, 
+												index_list **last_index_entry);
 
-static void
-register_index_position(int IndexOffset, index_list **last_index_entry)
+static void register_index_position(int IndexOffset, 
+												index_list **last_index_entry)
 {
       index_list *indexentry;
 
@@ -3023,7 +3019,7 @@
       }
 }
 
-static void Set_SCMS __PR(( unsigned long p_track ));
+static void Set_SCMS(unsigned long p_track);
 
 #undef DEBUG_INDLIST
 /* experimental code */
@@ -3422,7 +3418,7 @@
 	return -1;
 }
 
-int useHiddenTrack __PR(( void ));
+int useHiddenTrack(void);
 
 int useHiddenTrack()
 {
@@ -3431,7 +3427,7 @@
 
 
 
-static void it_reset __PR(( struct iterator *this ));
+static void it_reset(struct iterator *this);
 
 static void it_reset(struct iterator *this)
 {
@@ -3439,8 +3435,8 @@
 }
 
 
-static int it_hasNextTrack __PR(( struct iterator *this ));
-static struct TOC *it_getNextTrack __PR(( struct iterator *this ));
+static int it_hasNextTrack(struct iterator *this);
+static struct TOC *it_getNextTrack(struct iterator *this);
 
 static int it_hasNextTrack(struct iterator *this)
 {
@@ -3469,7 +3465,7 @@
 }
 
 #if	0
-static struct iterator *NewIterator __PR(( void ));
+static struct iterator *NewIterator(void);
 
 static struct iterator *NewIterator ()
 {
@@ -3706,49 +3702,49 @@
 }
 
 #ifdef	USE_PARANOIA
-long cdda_disc_firstsector __PR((void *d));
+long cdda_disc_firstsector(void *d);
 
 long cdda_disc_firstsector(void *d)
 {
 	return Get_StartSector(FirstAudioTrack());
 }
 
-int cdda_tracks __PR((void *d));
+int cdda_tracks(void *d);
 
 int cdda_tracks(void *d)
 {
 	return LastAudioTrack() - FirstAudioTrack() +1;
 }
 
-int cdda_track_audiop __PR((void *d, int track));
+int cdda_track_audiop(void *d, int track);
 
 int cdda_track_audiop(void *d, int track)
 {
 	return Get_Datatrack(track) == 0;
 }
 
-long cdda_track_firstsector __PR((void *d, int track));
+long cdda_track_firstsector(void *d, int track);
 
 long cdda_track_firstsector(void *d, int track)
 {
 	return Get_AudioStartSector(track);
 }
 
-long cdda_track_lastsector __PR((void *d, int track));
+long cdda_track_lastsector(void *d, int track);
 
 long cdda_track_lastsector(void *d, int track)
 {
 	return Get_EndSector(track);
 }
 
-long cdda_disc_lastsector __PR((void *d));
+long cdda_disc_lastsector(void *d);
 
 long cdda_disc_lastsector(void *d)
 {
 	return Get_LastSectorOnCd(cdtracks) - 1;
 }
 
-int cdda_sector_gettrack    __PR((void *d,long sector));
+int cdda_sector_gettrack(void *d,long sector);
 
 int cdda_sector_gettrack(void *d, long sector)
 {

Modified: nonameyet/branches/cleanup/cdda2wav/toc.h
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/toc.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/toc.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -24,45 +24,46 @@
 #undef	USE_REMOTE
 #else
 #define	USE_REMOTE	1
-extern	int		request_titles	__PR((void));
+extern	int		request_titles(void);
 #endif
 
-extern	int		ReadToc		__PR((void));
-extern	void		Check_Toc	__PR((void));
-extern	int		TOC_entries	__PR((unsigned tracks, unsigned char *a, unsigned char *b,
-						int bvalid));
-extern	void		toc_entry	__PR((unsigned nr, unsigned flag, unsigned tr,
-						unsigned char *ISRC,
-						unsigned long lba, int m, int s, int f));
-extern	int		patch_real_end	__PR((unsigned long sector));
-extern	int		no_disguised_audiotracks __PR((void));
+extern	int		ReadToc(void);
+extern	void		Check_Toc(void);
+extern	int		TOC_entries(unsigned tracks, 
+										unsigned char *a, unsigned char *b,
+										int bvalid);
+extern	void		toc_entry(unsigned nr, unsigned flag, unsigned tr,
+									 unsigned char *ISRC,
+									 unsigned long lba, int m, int s, int f);
+extern	int		patch_real_end(unsigned long sector);
+extern	int		no_disguised_audiotracks(void);
 
-extern	int		Get_Track	__PR((unsigned long sector));
-extern	long		FirstTrack	__PR((void));
-extern	long		LastTrack	__PR((void));
-extern	long		FirstAudioTrack	__PR((void));
-extern	long		FirstDataTrack	__PR((void));
-extern	long		LastAudioTrack	__PR((void));
-extern	long		Get_EndSector	__PR((unsigned long p_track));
-extern	long		Get_StartSector	__PR((unsigned long p_track));
-extern	long		Get_AudioStartSector	__PR((unsigned long p_track));
-extern	long		Get_LastSectorOnCd	__PR((unsigned long p_track));
-extern	int		CheckTrackrange	__PR((unsigned long from, unsigned long upto));
+extern	int		Get_Track(unsigned long sector);
+extern	long		FirstTrack(void);
+extern	long		LastTrack(void);
+extern	long		FirstAudioTrack(void);
+extern	long		FirstDataTrack(void);
+extern	long		LastAudioTrack(void);
+extern	long		Get_EndSector(unsigned long p_track);
+extern	long		Get_StartSector(unsigned long p_track);
+extern	long		Get_AudioStartSector(unsigned long p_track);
+extern	long		Get_LastSectorOnCd(unsigned long p_track);
+extern	int		CheckTrackrange(unsigned long from, unsigned long upto);
 
-extern	int		Get_Preemphasis	__PR((unsigned long p_track));
-extern	int		Get_Channels	__PR((unsigned long p_track));
-extern	int		Get_Copyright	__PR((unsigned long p_track));
-extern	int		Get_Datatrack	__PR((unsigned long p_track));
-extern	int		Get_Tracknumber	__PR((unsigned long p_track));
-extern	unsigned char *	Get_MCN		__PR((void));
-extern	unsigned char *	Get_ISRC	__PR((unsigned long p_track));
+extern	int		Get_Preemphasis(unsigned long p_track);
+extern	int		Get_Channels(unsigned long p_track);
+extern	int		Get_Copyright(unsigned long p_track);
+extern	int		Get_Datatrack(unsigned long p_track);
+extern	int		Get_Tracknumber(unsigned long p_track);
+extern	unsigned char *Get_MCN(void);
+extern	unsigned char *Get_ISRC(unsigned long p_track);
 
-extern	unsigned	find_an_off_sector __PR((unsigned lSector, unsigned SectorBurstVal));
-extern	void		DisplayToc	__PR((void));
-extern	unsigned	FixupTOC	__PR((unsigned no_tracks));
-extern	void		calc_cddb_id	__PR((void));
-extern	void		calc_cdindex_id	__PR((void));
-extern	void		Read_MCN_ISRC	__PR((void));
-extern	unsigned	ScanIndices	__PR((unsigned trackval, unsigned indexval, int bulk));
-extern	int		handle_cdtext	__PR((void));
-extern	int		lba_2_msf	__PR((long lba, int *m, int *s, int *f));
+extern	unsigned	find_an_off_sector(unsigned lSector, unsigned SectorBurstVal);
+extern	void		DisplayToc(void);
+extern	unsigned	FixupTOC(unsigned no_tracks);
+extern	void		calc_cddb_id(void);
+extern	void		calc_cdindex_id(void);
+extern	void		Read_MCN_ISRC(void);
+extern	unsigned	ScanIndices(unsigned trackval, unsigned indexval, int bulk);
+extern	int		handle_cdtext(void);
+extern	int		lba_2_msf(long lba, int *m, int *s, int *f);

Modified: nonameyet/branches/cleanup/cdda2wav/wav.c
===================================================================
--- nonameyet/branches/cleanup/cdda2wav/wav.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdda2wav/wav.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -91,7 +91,8 @@
 
 static WAVEHDR waveHdr;
 
-static int _InitSound __PR(( int audio, long channels, unsigned long rate, long nBitsPerSample, unsigned long expected_bytes ));
+static int _InitSound(int audio, long channels, unsigned long rate, 
+							 long nBitsPerSample, unsigned long expected_bytes);
 
 static int _InitSound(int audio, long channels, unsigned long rate, 
                       long nBitsPerSample, unsigned long expected_bytes)
@@ -117,7 +118,7 @@
   return write (audio, &waveHdr, sizeof (waveHdr));
 }
 
-static int _ExitSound __PR(( int audio, unsigned long nBytesDone ));
+static int _ExitSound(int audio, unsigned long nBytesDone);
 
 static int _ExitSound(int audio, unsigned long nBytesDone)
 {
@@ -133,14 +134,14 @@
   return write (audio, &waveHdr, sizeof (waveHdr));
 }
 
-static unsigned long _GetHdrSize __PR(( void ));
+static unsigned long _GetHdrSize(void);
 
 static unsigned long _GetHdrSize()
 {
   return sizeof( waveHdr );
 }
 
-static unsigned long InSizeToOutSize __PR(( unsigned long BytesToDo ));
+static unsigned long InSizeToOutSize(unsigned long BytesToDo);
 
 static unsigned long InSizeToOutSize(unsigned long BytesToDo)
 {
@@ -152,7 +153,10 @@
 	_InitSound,		/* init header method */
 	_ExitSound,		/* exit header method */
 	_GetHdrSize,		/* report header size method */
-	(int (*) __PR(( int audio, unsigned char *buf, unsigned long BytesToDo ))) write,			/* get sound samples out */
+	/* get sound samples out */
+	(int (*)(int audio, unsigned char *buf, unsigned long BytesToDo)) write,
 	InSizeToOutSize,	/* compressed? output file size */
 	0			/* needs big endian samples */
 };
+
+

Modified: nonameyet/branches/cleanup/cdrecord/audiosize.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/audiosize.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/audiosize.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -117,12 +117,12 @@
 				(((unsigned  char *)a)[3] << 24	& 0xFF000000)))
 #endif
 
-BOOL	is_auname	__PR((const char *name));
-off_t	ausize		__PR((int f));
-BOOL	is_wavname	__PR((const char *name));
-off_t	wavsize		__PR((int f));
+BOOL	is_auname(const char *name);
+off_t	ausize(int f);
+BOOL	is_wavname(const char *name);
+off_t	wavsize(int f);
 
-BOOL
+BOOL 
 is_auname(const char *name)
 {
 	const	char	*p;
@@ -135,7 +135,7 @@
 /*
  * Read Sun audio header, leave file seek pointer past auheader.
  */
-off_t
+off_t 
 ausize(int f)
 {
 	sun_au_t	hdr;
@@ -195,7 +195,7 @@
 	return ((off_t)ret);
 }
 
-BOOL
+BOOL 
 is_wavname(const char *name)
 {
 	const	char	*p;
@@ -208,7 +208,7 @@
 /*
  * Read WAV header, leave file seek pointer past WAV header.
  */
-off_t
+off_t 
 wavsize(int f)
 {
 	chunk_t		chunk;

Modified: nonameyet/branches/cleanup/cdrecord/auinfo.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/auinfo.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/auinfo.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -50,19 +50,20 @@
 extern	int	debug;
 extern	int	xdebug;
 
-BOOL	auinfosize	__PR((char *name, track_t *trackp));
-void	auinfo		__PR((char *name, int track, track_t *trackp));
-textptr_t *gettextptr	__PR((int track, track_t *trackp));
-static	char 	*savestr	__PR((char *name));
-static	char 	*readtag	__PR((char *name));
-static	char 	*readtstr	__PR((char *name));
-void	setmcn		__PR((char *mcn, track_t *trackp));
-static	void	isrc_illchar	__PR((char *isrc, int c));
-void	setisrc		__PR((char *isrc, track_t *trackp));
-void	setindex	__PR((char *tindex, track_t *trackp));
+BOOL			auinfosize(char *name, track_t *trackp);
+void			auinfo(char *name, int track, track_t *trackp);
+textptr_t 	*gettextptr(int track, track_t *trackp);
+static char *savestr(char *name);
+static char *readtag(char *name);
+static char *readtstr(char *name);
+void			setmcn(char *mcn, track_t *trackp);
+static void	isrc_illchar(char *isrc, int c);
+void			setisrc(char *isrc, track_t *trackp);
+void			setindex(char *tindex, track_t *trackp);
 
 #ifdef	XXX
-int main(int argc, char *argv[])
+int 
+main(int argc, char *argv[])
 {
 /*	auinfo("/etc/default/cdrecord");*/
 /*	auinfo("/mnt2/CD3/audio_01.inf");*/
@@ -70,7 +71,7 @@
 }
 #endif
 
-BOOL
+BOOL 
 auinfosize(char *name, track_t *trackp)
 {
 	const	char	*p;
@@ -147,7 +148,7 @@
 	return (TRUE);
 }
 
-void
+void 
 auinfo(char *name, int track, track_t *trackp)
 {
 	char	infname[1024];
@@ -368,7 +369,7 @@
 /*
  * Media catalog number is a 13 digit number.
  */
-void
+void 
 setmcn(char *mcn, track_t *trackp)
 {
 	register char	*p;
@@ -390,7 +391,7 @@
 
 static	char	upper[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
 
-static void
+static void 
 isrc_illchar(char *isrc, int c)
 {
 	errmsgno(EX_BAD, "ISRC '%s' contains illegal character '%c'.\n", isrc, c);
@@ -406,7 +407,7 @@
  *
  *	CC-OOO-YY-SSSSS
  */
-void
+void 
 setisrc(char *isrc, track_t *trackp)
 {
 	char	ibuf[13];
@@ -484,7 +485,7 @@
 	exit(EX_BAD);
 }
 
-void
+void 
 setindex(char *tindex, track_t *trackp)
 {
 	char	*p;

Modified: nonameyet/branches/cleanup/cdrecord/cd_misc.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/cd_misc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/cd_misc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -43,26 +43,26 @@
 
 #include "cdrecord.h"
 
-int	from_bcd		__PR((int b));
-int	to_bcd			__PR((int i));
-long	msf_to_lba		__PR((int m, int s, int f, BOOL force_positive));
-BOOL	lba_to_msf		__PR((long lba, msf_t *mp));
-void	sec_to_msf		__PR((long sec, msf_t *mp));
-void	print_min_atip		__PR((long li, long lo));
+int	from_bcd(int b);
+int	to_bcd(int i);
+long	msf_to_lba(int m, int s, int f, BOOL force_positive);
+BOOL	lba_to_msf(long lba, msf_t *mp);
+void	sec_to_msf(long sec, msf_t *mp);
+void	print_min_atip(long li, long lo);
 
-int
+int 
 from_bcd(int b)
 {
 	return ((b & 0x0F) + 10 * (((b)>> 4) & 0x0F));
 }
 
-int
+int 
 to_bcd(int i)
 {
 	return (i % 10 | ((i / 10) % 10) << 4);
 }
 
-long
+long 
 msf_to_lba(int m, int s, int f, BOOL force_positive)
 {
 	long	ret = m * 60 + s;
@@ -76,7 +76,7 @@
 	return (ret);
 }
 
-BOOL
+BOOL 
 lba_to_msf(long lba, msf_t *mp)
 {
 	int	m;
@@ -113,7 +113,7 @@
 	return (TRUE);
 }
 
-void
+void 
 sec_to_msf(long sec, msf_t *mp)
 {
 	int	m;
@@ -129,7 +129,7 @@
 	mp->msf_frame = f;
 }
 
-void
+void 
 print_min_atip(long li, long lo)
 {
 	msf_t	msf;

Modified: nonameyet/branches/cleanup/cdrecord/cdr_drv.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/cdr_drv.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/cdr_drv.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -73,18 +73,18 @@
 extern	cdr_t	cdr_cdr_simul;
 extern	cdr_t	cdr_dvd_simul;
 
-cdr_t 	*drive_identify		__PR((SCSI *scgp, cdr_t *, struct scsi_inquiry *ip));
-int	drive_attach		__PR((SCSI *scgp, cdr_t *));
-int	attach_unknown		__PR((void));
-int	blank_dummy		__PR((SCSI *scgp, cdr_t *, long addr, int blanktype));
-int	format_dummy		__PR((SCSI *scgp, cdr_t *, int fmtflags));
-int	drive_getdisktype	__PR((SCSI *scgp, cdr_t *dp));
-int	cmd_ill			__PR((SCSI *scgp));
-int	cmd_dummy		__PR((SCSI *scgp, cdr_t *));
-int	no_sendcue		__PR((SCSI *scgp, cdr_t *, track_t *trackp));
-int	buf_dummy		__PR((SCSI *scgp, long *sp, long *fp));
-BOOL	set_cdrcmds		__PR((char *name, cdr_t **dpp));
-cdr_t	*get_cdrcmds		__PR((SCSI *scgp));
+cdr_t 	*drive_identify(SCSI *scgp, cdr_t *, struct scsi_inquiry *ip);
+int	drive_attach(SCSI *scgp, cdr_t *);
+int	attach_unknown(void);
+int	blank_dummy(SCSI *scgp, cdr_t *, long addr, int blanktype);
+int	format_dummy(SCSI *scgp, cdr_t *, int fmtflags);
+int	drive_getdisktype(SCSI *scgp, cdr_t *dp);
+int	cmd_ill(SCSI *scgp);
+int	cmd_dummy(SCSI *scgp, cdr_t *);
+int	no_sendcue(SCSI *scgp, cdr_t *, track_t *trackp);
+int	buf_dummy(SCSI *scgp, long *sp, long *fp);
+BOOL	set_cdrcmds(char *name, cdr_t **dpp);
+cdr_t	*get_cdrcmds(SCSI *scgp);
 
 /*
  * List of CD-R drivers
@@ -121,67 +121,67 @@
 	return (dp);
 }
 
-int
+int 
 drive_attach(SCSI *scgp, cdr_t *dp)
 {
 	return (0);
 }
 
-int
+int 
 attach_unknown()
 {
 	errmsgno(EX_BAD, "Unsupported drive type\n");
 	return (-1);
 }
 
-int
+int 
 blank_dummy(SCSI *scgp, cdr_t *dp, long addr, int blanktype)
 {
 	printf("This drive or media does not support the 'BLANK media' command\n");
 	return (-1);
 }
 
-int
+int 
 format_dummy(SCSI *scgp, cdr_t *dp, int fmtflags)
 {
 	printf("This drive or media does not support the 'FORMAT media' command\n");
 	return (-1);
 }
 
-int
+int 
 drive_getdisktype(SCSI *scgp, cdr_t *dp)
 {
 /*	dstat_t	*dsp = dp->cdr_dstat;*/
 	return (0);
 }
 
-int
+int 
 cmd_ill(SCSI *scgp)
 {
 	errmsgno(EX_BAD, "Unspecified command not implemented for this drive.\n");
 	return (-1);
 }
 
-int
+int 
 cmd_dummy(SCSI *scgp, cdr_t *dp)
 {
 	return (0);
 }
 
-int
+int 
 no_sendcue(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	errmsgno(EX_BAD, "SAO writing not available or not implemented for this drive.\n");
 	return (-1);
 }
 
-int
+int 
 buf_dummy(SCSI *scgp, long *sp, long *fp)
 {
 	return (-1);
 }
 
-BOOL
+BOOL 
 set_cdrcmds(char *name, cdr_t **dpp)
 {
 	cdr_t	**d;

Modified: nonameyet/branches/cleanup/cdrecord/cdrecord.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/cdrecord.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/cdrecord.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -196,80 +196,71 @@
 
 static	long	fs = -1L;	/* fifo (ring buffer) size */
 
-static	int	gracewait	__PR((cdr_t *dp, BOOL *didgracep));
-static	void	cdrstats	__PR((cdr_t *dp));
-static	void	susage		__PR((int));
-static	void	usage		__PR((int));
-static	void	blusage		__PR((int));
-static	void	formattypeusage	__PR((int));
-static	void	intr		__PR((int sig));
-static	void	catchsig	__PR((int sig));
-static	int	scsi_cb		__PR((void *arg));
-static	void	intfifo		__PR((int sig));
-static	void	exscsi		__PR((int excode, void *arg));
-static	void	excdr		__PR((int excode, void *arg));
-int	read_buf	__PR((int f, char *bp, int size));
-int	fill_buf	__PR((int f, track_t *trackp, long secno,
-							char *bp, int size));
-int	get_buf		__PR((int f, track_t *trackp, long secno,
-							char **bpp, int size));
-int	write_secs	__PR((SCSI *scgp, cdr_t *dp, char *bp,
-						long startsec, int bytespt,
-						int secspt, BOOL islast));
-static	int	write_track_data __PR((SCSI *scgp, cdr_t *, track_t *));
-int	pad_track	__PR((SCSI *scgp, cdr_t *dp,
-					track_t *trackp,
-					long startsec, Llong amt,
-					BOOL dolast, Llong *bytesp));
-int	write_buf	__PR((SCSI *scgp, cdr_t *dp,
-					track_t *trackp,
-					char *bp, long startsec, Llong amt,
-					int secsize,
-					BOOL dolast, Llong *bytesp));
-static	void	printdata	__PR((int, track_t *));
-static	void	printaudio	__PR((int, track_t *));
-static	void	checkfile	__PR((int, track_t *));
-static	int	checkfiles	__PR((int, track_t *));
-static	void	setleadinout	__PR((int, track_t *));
-static	void	setpregaps	__PR((int, track_t *));
-static	long	checktsize	__PR((int, track_t *));
-static	void	opentracks	__PR((track_t *));
-static	void	checksize	__PR((track_t *));
-static	BOOL	checkdsize	__PR((SCSI *scgp, cdr_t *dp,
-					long tsize, int flags));
-static	void	raise_fdlim	__PR((void));
-static	void	raise_memlock	__PR((void));
-static	int	gargs		__PR((int, char **, int *, track_t *, char **,
-					int *, cdr_t **,
-					int *, long *, int *, int *));
-static	void	set_trsizes	__PR((cdr_t *, int, track_t *));
-void	load_media	__PR((SCSI *scgp, cdr_t *, BOOL));
-void	unload_media	__PR((SCSI *scgp, cdr_t *, int));
-void	reload_media	__PR((SCSI *scgp, cdr_t *));
-void	set_secsize	__PR((SCSI *scgp, int secsize));
-static	int	get_dmaspeed	__PR((SCSI *scgp, cdr_t *));
-static	BOOL	do_opc		__PR((SCSI *scgp, cdr_t *, int));
-static	void	check_recovery	__PR((SCSI *scgp, cdr_t *, int));
-	void	audioread	__PR((SCSI *scgp, cdr_t *, int));
-static	void	print_msinfo	__PR((SCSI *scgp, cdr_t *));
-static	void	print_toc	__PR((SCSI *scgp, cdr_t *));
-static	void	print_track	__PR((int, long, struct msf *, int, int, int));
+static	int	gracewait(cdr_t *dp, BOOL *didgracep);
+static	void	cdrstats(cdr_t *dp);
+static	void	susage(int);
+static	void	usage(int);
+static	void	blusage(int);
+static	void	formattypeusage(int);
+static	void	intr(int sig);
+static	void	catchsig(int sig);
+static	int	scsi_cb(void *arg);
+static	void	intfifo(int sig);
+static	void	exscsi(int excode, void *arg);
+static	void	excdr(int excode, void *arg);
+int	read_buf(int f, char *bp, int size);
+int	fill_buf(int f, track_t *trackp, long secno, char *bp, int size);
+int	get_buf(int f, track_t *trackp, long secno, char **bpp, int size);
+int	write_secs(SCSI *scgp, cdr_t *dp, char *bp, long startsec, int bytespt,
+					  int secspt, BOOL islast);
+static	int	write_track_data(SCSI *scgp, cdr_t *, track_t *);
+int	pad_track(SCSI *scgp, cdr_t *dp, track_t *trackp, long startsec, 
+					 Llong amt, BOOL dolast, Llong *bytesp);
+int	write_buf(SCSI *scgp, cdr_t *dp, track_t *trackp, char *bp, 
+					 long startsec, Llong amt, int secsize, BOOL dolast, 
+					 Llong *bytesp);
+static	void	printdata(int, track_t *);
+static	void	printaudio(int, track_t *);
+static	void	checkfile(int, track_t *);
+static	int	checkfiles(int, track_t *);
+static	void	setleadinout(int, track_t *);
+static	void	setpregaps(int, track_t *);
+static	long	checktsize(int, track_t *);
+static	void	opentracks(track_t *);
+static	void	checksize(track_t *);
+static	BOOL	checkdsize(SCSI *scgp, cdr_t *dp, long tsize, int flags);
+static	void	raise_fdlim(void);
+static	void	raise_memlock(void);
+static	int	gargs(int, char **, int *, track_t *, char **, int *, cdr_t **,
+							int *, long *, int *, int *);
+static	void	set_trsizes(cdr_t *, int, track_t *);
+void		load_media(SCSI *scgp, cdr_t *, BOOL);
+void		unload_media(SCSI *scgp, cdr_t *, int);
+void		reload_media(SCSI *scgp, cdr_t *);
+void		set_secsize(SCSI *scgp, int secsize);
+static	int	get_dmaspeed(SCSI *scgp, cdr_t *);
+static	BOOL	do_opc(SCSI *scgp, cdr_t *, int);
+static	void	check_recovery(SCSI *scgp, cdr_t *, int);
+void		audioread(SCSI *scgp, cdr_t *, int);
+static	void	print_msinfo(SCSI *scgp, cdr_t *);
+static	void	print_toc(SCSI *scgp, cdr_t *);
+static	void	print_track(int, long, struct msf *, int, int, int);
 #if !defined(HAVE_SYS_PRIOCNTL_H)
-static	int	rt_raisepri	__PR((int));
+static	int	rt_raisepri(int);
 #endif
-void	raisepri	__PR((int));
-static	void	wait_input	__PR((void));
-static	void	checkgui	__PR((void));
-static	int	getbltype	__PR((char *optstr, long *typep));
-static	int	getformattype	__PR((char *optstr, long *typep));
-static	void	print_drflags	__PR((cdr_t *dp));
-static	void	print_wrmodes	__PR((cdr_t *dp));
-static	BOOL	check_wrmode	__PR((cdr_t *dp, int wmode, int tflags));
-static	void	set_wrmode	__PR((cdr_t *dp, int wmode, int tflags));
-static	void	linuxcheck	__PR((void));
+void		raisepri(int);
+static	void	wait_input(void);
+static	void	checkgui(void);
+static	int	getbltype(char *optstr, long *typep);
+static	int	getformattype(char *optstr, long *typep);
+static	void	print_drflags(cdr_t *dp);
+static	void	print_wrmodes(cdr_t *dp);
+static	BOOL	check_wrmode(cdr_t *dp, int wmode, int tflags);
+static	void	set_wrmode(cdr_t *dp, int wmode, int tflags);
+static	void	linuxcheck(void);
 
 #ifdef __linux__
-static int get_cap   __PR((cap_value_t cap_array));
+static int get_cap(cap_value_t cap_array);
 #endif
 
 struct exargs {
@@ -280,7 +271,7 @@
 	int	exflags;
 } exargs;
 
-int
+int 
 main(int argc, char *argv[])
 {
 	char	*dev = NULL;
@@ -597,7 +588,7 @@
  * Debug only
  */
 {
-extern	void	gconf	__PR((SCSI *));
+extern	void	gconf(SCSI *);
 
 if (lverbose > 2)
 	gconf(scgp);
@@ -1489,7 +1480,7 @@
 	return (0);
 }
 
-static int
+static int 
 gracewait(cdr_t *dp, BOOL *didgracep)
 {
 	int	i;
@@ -1560,7 +1551,7 @@
 	return (0);
 }
 
-static void
+static void 
 cdrstats(cdr_t *dp)
 {
 	float	secsps = 75.0;
@@ -1652,7 +1643,7 @@
 	/* NOTREACHED */
 }
 
-static void
+static void 
 usage(int excode)
 {
 	error("Usage: %s [options] track1...trackn\n", get_progname());
@@ -1747,7 +1738,7 @@
 	exit(excode);
 }
 
-static void
+static void 
 blusage(int ret)
 {
 	error("Blanking options:\n");
@@ -1766,7 +1757,7 @@
 	/* NOTREACHED */
 }
 
-static void
+static void 
 formattypeusage(int ret)
 {
 	error("Formating options:\n");
@@ -1789,13 +1780,13 @@
 	didintr++;
 }
 
-static void
+static void 
 catchsig(int sig)
 {
 	signal(sig, catchsig);
 }
 
-static int
+static int 
 scsi_cb(void *arg)
 {
 	comexit(EX_BAD);
@@ -1803,7 +1794,7 @@
 	return (0);	/* Keep lint happy */
 }
 
-static void
+static void 
 intfifo(int sig)
 {
 	errmsgno(EX_BAD, "Caught interrupt.\n");
@@ -1824,7 +1815,7 @@
 }
 
 /* ARGSUSED */
-static void
+static void 
 exscsi(int excode, void *arg)
 {
 	struct exargs	*exp = (struct exargs *)arg;
@@ -1850,7 +1841,7 @@
 	}
 }
 
-static void
+static void 
 excdr(int excode, void *arg)
 {
 	struct exargs	*exp = (struct exargs *)arg;
@@ -1871,7 +1862,7 @@
 #endif
 }
 
-int
+int 
 read_buf(int f, char *bp, int size)
 {
 	char	*p = bp;
@@ -1891,7 +1882,7 @@
 	return (amount);
 }
 
-int
+int 
 fill_buf(int f, track_t *trackp, long secno, char *bp, int size)
 {
 	int	amount = 0;
@@ -1967,7 +1958,7 @@
 	return (amount);
 }
 
-int
+int 
 get_buf(int f, track_t *trackp, long secno, char **bpp, int size)
 {
 	if (fs > 0) {
@@ -1978,9 +1969,9 @@
 	}
 }
 
-int
+int 
 write_secs(SCSI *scgp, cdr_t *dp, char *bp, long startsec, int bytespt, 
-        int secspt, BOOL islast)
+        		int secspt, BOOL islast)
 {
 	int	amount;
 
@@ -2018,7 +2009,7 @@
 	return (amount);
 }
 
-static int
+static int 
 write_track_data(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	int	track = trackp->trackno;
@@ -2301,9 +2292,9 @@
 	return (0);
 }
 
-int
+int 
 pad_track(SCSI *scgp, cdr_t	*dp, track_t *trackp, long startsec, Llong amt,
-	BOOL dolast, Llong *bytesp)
+				BOOL dolast, Llong *bytesp)
 {
 	int	track = trackp->trackno;
 	Llong	bytes	= 0;
@@ -2435,9 +2426,9 @@
 }
 
 #ifdef	USE_WRITE_BUF
-int
+int 
 write_buf(SCSI *scgp, cdr_t *dp, track_t *trackp, char *bp, long startsec, 
-        Llong amt, int secsize, BOOL dolast, Llong *bytesp)
+        	  Llong amt, int secsize, BOOL dolast, Llong *bytesp)
 {
 	int	track = trackp->trackno;
 	Llong	bytes	= 0;
@@ -2498,7 +2489,7 @@
 }
 #endif	/* USE_WRITE_BUF */
 
-static void
+static void 
 printdata(int track, track_t *trackp)
 {
 	if (trackp->itracksize >= 0) {
@@ -2525,7 +2516,7 @@
 	printf("\n");
 }
 
-static void
+static void 
 printaudio(int track, track_t *trackp)
 {
 	if (trackp->itracksize >= 0) {
@@ -2573,7 +2564,7 @@
 	printf("\n");
 }
 
-static void
+static void 
 checkfile(int track, track_t *trackp)
 {
 	if (trackp->itracksize > 0 &&
@@ -2602,7 +2593,7 @@
 		printdata(track, trackp);
 }
 
-static int
+static int 
 checkfiles(int tracks, track_t *trackp)
 {
 	int	i;
@@ -2627,7 +2618,7 @@
 	return (isaudio);
 }
 
-static void
+static void 
 setleadinout(int tracks, track_t *trackp)
 {
 	/*
@@ -2662,7 +2653,7 @@
 	trackp[tracks+1].flags = trackp[tracks].flags;
 }
 
-static void
+static void 
 setpregaps(int tracks, track_t *trackp)
 {
 	int	i;
@@ -2705,7 +2696,7 @@
 /*
  * Check total size of the medium
  */
-static long
+static long 
 checktsize(int tracks, track_t *trackp)
 {
 	int	i;
@@ -2782,7 +2773,7 @@
 	return (total);
 }
 
-static void
+static void 
 opentracks(track_t *trackp)
 {
 	track_t	*tp;
@@ -2856,7 +2847,7 @@
 	}
 }
 
-static void
+static void 
 checksize(track_t *trackp)
 {
 	struct stat	st;
@@ -2913,7 +2904,7 @@
 	}
 }
 
-static BOOL
+static BOOL 
 checkdsize(SCSI *scgp, cdr_t *dp, long tsize, int flags)
 {
 	long	startsec = 0L;
@@ -3082,7 +3073,7 @@
 	return (FALSE);
 }
 
-static void
+static void 
 raise_fdlim()
 {
 #ifdef	RLIMIT_NOFILE
@@ -3106,7 +3097,7 @@
 #endif	/* RLIMIT_NOFILE */
 }
 
-static void
+static void 
 raise_memlock()
 {
 #ifdef	RLIMIT_MEMLOCK
@@ -3129,10 +3120,10 @@
 #define	M_SAO		2	/* Session at Once mode (also known as DAO) */
 #define	M_RAW		4	/* Raw mode */
 #define	M_PACKET	8	/* Packed mode */
-static int
+static int 
 gargs(int ac, char **av, int *tracksp, track_t *trackp, char **devp, 
-        int *timeoutp, cdr_t **dpp, int *speedp, long *flagsp, int *blankp, 
-        int *formatp)
+		int *timeoutp, cdr_t **dpp, int *speedp, long *flagsp, int *blankp, 
+		int *formatp)
 {
 	int	cac;
 	char	* const*cav;
@@ -3837,7 +3828,7 @@
 	return ispacket;
 }
 
-static void
+static void 
 set_trsizes(cdr_t *dp, int tracks, track_t *trackp)
 {
 	int	i;
@@ -3892,7 +3883,7 @@
 		printf("Set Transfersizes end\n");
 }
 
-void
+void 
 load_media(SCSI *scgp, cdr_t *dp, BOOL doexit)
 {
 	int	code;
@@ -3938,7 +3929,7 @@
 	wait_unit_ready(scgp, 120);
 }
 
-void
+void 
 unload_media(SCSI *scgp, cdr_t *dp, int flags)
 {
 	scsi_prevent_removal(scgp, 0);
@@ -3948,7 +3939,7 @@
 	}
 }
 
-void
+void 
 reload_media(SCSI *scgp, cdr_t *dp)
 {
 	char	ans[2];
@@ -4003,7 +3994,7 @@
 	load_media(scgp, dp, TRUE);
 }
 
-void
+void 
 set_secsize(SCSI *scgp, int secsize)
 {
 	if (secsize > 0) {
@@ -4016,7 +4007,7 @@
 	}
 }
 
-static int
+static int 
 get_dmaspeed(SCSI *scgp, cdr_t *dp)
 {
 	int	i;
@@ -4063,7 +4054,7 @@
 }
 
 
-static BOOL
+static BOOL 
 do_opc(SCSI *scgp, cdr_t *dp, int flags)
 {
 	if ((flags & F_DUMMY) == 0 && dp->cdr_opc) {
@@ -4080,7 +4071,7 @@
 	return (TRUE);
 }
 
-static void
+static void 
 check_recovery(SCSI *scgp, cdr_t *dp, int flags)
 {
 	if ((*dp->cdr_check_recovery)(scgp, dp)) {
@@ -4093,7 +4084,7 @@
 #ifndef	DEBUG
 #define	DEBUG
 #endif
-void
+void 
 audioread(SCSI *scgp, cdr_t *dp, int flags)
 {
 #ifdef	DEBUG
@@ -4118,7 +4109,7 @@
 #endif
 }
 
-static void
+static void 
 print_msinfo(SCSI *scgp, cdr_t *dp)
 {
 	long	off;
@@ -4138,7 +4129,7 @@
 	printf("%ld,%ld\n", off, fa);
 }
 
-static void
+static void 
 print_toc(SCSI *scgp, cdr_t *dp)
 {
 	int	first;
@@ -4186,8 +4177,9 @@
 	}
 }
 
-static void
-print_track(int track, long lba, struct msf *msp, int adr, int control, int mode)
+static void 
+print_track(int track, long lba, struct msf *msp, int adr, 
+				int control, int mode)
 {
 	long	lba_512 = lba*4;
 
@@ -4210,7 +4202,7 @@
 #include <sys/priocntl.h>
 #include <sys/rtpriocntl.h>
 
-void
+void 
 raisepri(int pri)
 {
 	int		pid;
@@ -4264,7 +4256,7 @@
 #undef	_P
 #endif
 
-static	int
+static int 
 rt_raisepri(int pri)
 {
 	struct sched_param scp;
@@ -4315,7 +4307,7 @@
 #undef format
 #undef interface
 
-static	int
+static int 
 rt_raisepri(int pri)
 {
 	int prios[] = {THREAD_PRIORITY_TIME_CRITICAL, THREAD_PRIORITY_HIGHEST};
@@ -4338,7 +4330,7 @@
 /*
  * This OS does not support real time scheduling.
  */
-static	int
+static int 
 rt_raisepri(int pri)
 {
 	return (-1);
@@ -4348,7 +4340,7 @@
 
 #endif	/* _POSIX_PRIORITY_SCHEDULING */
 
-void
+void 
 raisepri(int pri)
 {
 	if (rt_raisepri(pri) >= 0)
@@ -4402,7 +4394,7 @@
 #include <sys/socket.h>
 #endif
 
-static void
+static void 
 wait_input()
 {
 #ifdef	HAVE_SELECT
@@ -4421,7 +4413,7 @@
 #endif
 }
 
-static void
+static void 
 checkgui()
 {
 	struct stat st;
@@ -4433,7 +4425,7 @@
 	}
 }
 
-static int
+static int 
 getbltype(char *optstr, long *typep)
 {
 	if (streql(optstr, "all")) {
@@ -4466,7 +4458,7 @@
 	return (TRUE);
 }
 
-static int
+static int 
 getformattype(char *optstr, long *typep)
 {
 	if (streql(optstr, "full")) {
@@ -4484,7 +4476,7 @@
 	}
 	return (TRUE);
 }
-static void
+static void 
 print_drflags(cdr_t *dp)
 {
 	printf("Driver flags   : ");
@@ -4522,7 +4514,7 @@
 	printf("\n");
 }
 
-static void
+static void 
 print_wrmodes(cdr_t *dp)
 {
 	BOOL	needblank = FALSE;
@@ -4569,7 +4561,7 @@
 	printf("\n");
 }
 
-static BOOL
+static BOOL 
 check_wrmode(cdr_t *dp, int wmode, int tflags)
 {
 	int	cdflags = dp->cdr_flags;
@@ -4639,7 +4631,7 @@
 	return (FALSE);
 }
 
-static void
+static void 
 set_wrmode(cdr_t *dp, int wmode, int tflags)
 {
 	dstat_t	*dsp = dp->cdr_dstat;
@@ -4695,7 +4687,7 @@
 #endif
 
 #ifdef __linux__
-static int
+static int 
 get_cap(cap_value_t cap_array)
 { 
     	  int ret;

Modified: nonameyet/branches/cleanup/cdrecord/cdrecord.h
===================================================================
--- nonameyet/branches/cleanup/cdrecord/cdrecord.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/cdrecord.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -712,52 +712,84 @@
 
 #ifdef	_SCG_SCSITRANSP_H
 struct cdr_cmd {
-	int	cdr_dev;			/* Numerical device type */
+	int	cdr_dev;						/* Numerical device type */
 	UInt32_t cdr_cmdflags;			/* Command line options */
-	UInt32_t cdr_flags;			/* Drive related flags	*/
-	UInt8_t	 cdr_cdrw_support;		/* CD-RW write media types */
+	UInt32_t cdr_flags;				/* Drive related flags	*/
+	UInt8_t	 cdr_cdrw_support;	/* CD-RW write media types */
 	UInt16_t cdr_speeddef;			/* Default write speed	*/
 	UInt16_t cdr_speedmax;			/* Max. write speed	*/
 
-	char	*cdr_drname;			/* Driver ID string	*/
-	char	*cdr_drtext;			/* Driver ID text	*/
+	char	*cdr_drname;				/* Driver ID string	*/
+	char	*cdr_drtext;				/* Driver ID text	*/
 	struct cd_mode_page_2A *cdr_cdcap;
 	dstat_t	*cdr_dstat;
 #ifdef	_SCG_SCSIREG_H
-	cdr_t	*(*cdr_identify)	__PR((SCSI *scgp, cdr_t *, struct scsi_inquiry *));	/* identify drive */
+	/* identify drive */
+	cdr_t	*(*cdr_identify)(SCSI *scgp, cdr_t *, struct scsi_inquiry *);	
 #else
-	cdr_t	*(*cdr_identify)	__PR((SCSI *scgp, cdr_t *, void *));		/* identify drive */
+	/* identify drive */
+	cdr_t	*(*cdr_identify)(SCSI *scgp, cdr_t *, void *);		
 #endif
-	int	(*cdr_attach)		__PR((SCSI *scgp, cdr_t *));			/* init error decoding etc*/
-	int	(*cdr_init)		__PR((SCSI *scgp, cdr_t *));			/* init drive to useful deflts */
-	int	(*cdr_getdisktype)	__PR((SCSI *scgp, cdr_t *));			/* get disk type */
-	int	(*cdr_load)		__PR((SCSI *scgp, cdr_t *));			/* load disk */
-	int	(*cdr_unload)		__PR((SCSI *scgp, cdr_t *));			/* unload disk */
-	int	(*cdr_buffer_cap)	__PR((SCSI *scgp, long *sizep, long *freep));	/* read buffer capacity */
-	int	(*cdr_check_recovery)	__PR((SCSI *scgp, cdr_t *));			/* check if recover is needed */
-	int	(*cdr_recover)		__PR((SCSI *scgp, cdr_t *, int track));		/* do recover */
-	int	(*cdr_set_speed_dummy)	__PR((SCSI *scgp, cdr_t *, int *speedp));	/* set recording speed & dummy write */
-	int	(*cdr_set_secsize)	__PR((SCSI *scgp, int secsize));		/* set sector size */
-	int	(*cdr_next_wr_address)	__PR((SCSI *scgp, track_t *trackp, long *ap));	/* get next writable addr. */
-	int	(*cdr_reserve_track)	__PR((SCSI *scgp, Ulong len));			/* reserve track for future use */
-	int	(*cdr_write_trackdata)	__PR((SCSI *scgp, caddr_t buf, long daddr, long bytecnt, int seccnt, BOOL islast));
-	int	(*cdr_gen_cue)		__PR((track_t *trackp, void *cuep, BOOL needgap));		/* generate cue sheet */
-	int	(*cdr_send_cue)		__PR((SCSI *scgp, cdr_t *, track_t *trackp));	/* send cue sheet */
-	int	(*cdr_write_leadin)	__PR((SCSI *scgp, cdr_t *, track_t *trackp));	/* write leadin */
-	int	(*cdr_open_track)	__PR((SCSI *scgp, cdr_t *, track_t *trackp));	/* open new track */
-	int	(*cdr_close_track)	__PR((SCSI *scgp, cdr_t *, track_t *trackp));	/* close written track */
-	int	(*cdr_open_session)	__PR((SCSI *scgp, cdr_t *, track_t *trackp));	/* open new session */
-	int	(*cdr_close_session)	__PR((SCSI *scgp, cdr_t *));			/* really needed ??? */
-	int	(*cdr_abort_session)	__PR((SCSI *scgp, cdr_t *));			/* abort current write */
-	int	(*cdr_session_offset)	__PR((SCSI *scgp, long *soff));			/* read session offset*/
-	int	(*cdr_fixate)		__PR((SCSI *scgp, cdr_t *, track_t *trackp));	/* write toc on disk */
-	int	(*cdr_stats)		__PR((SCSI *scgp, cdr_t *));			/* final statistics printing*/
-	int	(*cdr_blank)		__PR((SCSI *scgp, cdr_t *, long addr, int blanktype));	/* blank something */
-	int	(*cdr_format)		__PR((SCSI *scgp, cdr_t *, int fmtflags));	/* format media */
-	int	(*cdr_opc)		__PR((SCSI *scgp, caddr_t bp, int cnt, int doopc));	/* Do OPC */
-	int	(*cdr_opt1)		__PR((SCSI *scgp, cdr_t *));			/* do early option processing*/
-	int	(*cdr_opt2)		__PR((SCSI *scgp, cdr_t *));			/* do late option processing */
-	int	(*cdr_layer_split)	__PR((SCSI *scgp, cdr_t *, long tsize));	/* calculate optimale split */
+	/* init error decoding etc*/
+	int	(*cdr_attach)(SCSI *scgp, cdr_t *);
+	/* init drive to useful deflts */
+	int	(*cdr_init)(SCSI *scgp, cdr_t *);
+	/* get disk type */
+	int	(*cdr_getdisktype)(SCSI *scgp, cdr_t *);
+	/* load disk */
+	int	(*cdr_load)(SCSI *scgp, cdr_t *);
+	/* unload disk */
+	int	(*cdr_unload)(SCSI *scgp, cdr_t *);	
+	/* read buffer capacity */
+	int	(*cdr_buffer_cap)(SCSI *scgp, long *sizep, long *freep);
+	/* check if recover is needed */
+	int	(*cdr_check_recovery)(SCSI *scgp, cdr_t *);
+	/* do recover */
+	int	(*cdr_recover)(SCSI *scgp, cdr_t *, int track);
+	/* set recording speed & dummy write */
+	int	(*cdr_set_speed_dummy)(SCSI *scgp, cdr_t *, int *speedp);
+	/* set sector size */
+	int	(*cdr_set_secsize)(SCSI *scgp, int secsize);
+	/* get next writable addr. */
+	int	(*cdr_next_wr_address)(SCSI *scgp, track_t *trackp, long *ap);
+	/* reserve track for future use */
+	int	(*cdr_reserve_track)(SCSI *scgp, Ulong len);
+	int	(*cdr_write_trackdata)(SCSI *scgp, caddr_t buf, long daddr, long bytecnt, 
+										  int seccnt, BOOL islast);
+	/* generate cue sheet */
+	int	(*cdr_gen_cue)(track_t *trackp, void *cuep, BOOL needgap);
+	/* send cue sheet */
+	int	(*cdr_send_cue)(SCSI *scgp, cdr_t *, track_t *trackp);
+	/* write leadin */
+	int	(*cdr_write_leadin)(SCSI *scgp, cdr_t *, track_t *trackp);
+	/* open new track */
+	int	(*cdr_open_track)(SCSI *scgp, cdr_t *, track_t *trackp);
+	/* close written track */
+	int	(*cdr_close_track)(SCSI *scgp, cdr_t *, track_t *trackp);
+	/* open new session */
+	int	(*cdr_open_session)(SCSI *scgp, cdr_t *, track_t *trackp);
+	/* really needed ??? */
+	int	(*cdr_close_session)(SCSI *scgp, cdr_t *);
+	/* abort current write */
+	int	(*cdr_abort_session)(SCSI *scgp, cdr_t *);
+	/* read session offset*/
+	int	(*cdr_session_offset)(SCSI *scgp, long *soff);
+	/* write toc on disk */
+	int	(*cdr_fixate)(SCSI *scgp, cdr_t *, track_t *trackp);
+	/* final statistics printing*/
+	int	(*cdr_stats)(SCSI *scgp, cdr_t *);
+	/* blank something */
+	int	(*cdr_blank)(SCSI *scgp, cdr_t *, long addr, int blanktype);
+	/* format media */
+	int	(*cdr_format)(SCSI *scgp, cdr_t *, int fmtflags);
+	/* Do OPC */
+	int	(*cdr_opc)(SCSI *scgp, caddr_t bp, int cnt, int doopc);
+	/* do early option processing*/
+	int	(*cdr_opt1)(SCSI *scgp, cdr_t *);
+	/* do late option processing */
+	int	(*cdr_opt2)(SCSI *scgp, cdr_t *);
+	/* calculate optimale split */
+	int	(*cdr_layer_split)(SCSI *scgp, cdr_t *, long tsize);
 	int	profile;
 	BOOL	is_dvd;
 };
@@ -816,49 +848,50 @@
 /*
  * cdrecord.c
  */
-extern	int	read_buf	__PR((int f, char *bp, int size));
-extern	int	fill_buf	__PR((int f, track_t *trackp, long secno, char *bp, int size));
-extern	int	get_buf		__PR((int f, track_t *trackp, long secno, char **bpp, int size));
+extern	int	read_buf(int f, char *bp, int size);
+extern	int	fill_buf(int f, track_t *trackp, long secno, char *bp, int size);
+extern	int	get_buf(int f, track_t *trackp, long secno, char **bpp, int size);
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	write_secs	__PR((SCSI *scgp, cdr_t *dp, char *bp, long startsec, int bytespt, int secspt, BOOL islast));
-extern	int	pad_track	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp,
-					long startsec, Llong amt,
-					BOOL dolast, Llong *bytesp));
-extern	void	load_media	__PR((SCSI *scgp, cdr_t *, BOOL));
-extern	void	unload_media	__PR((SCSI *scgp, cdr_t *, int));
-extern	void	reload_media	__PR((SCSI *scgp, cdr_t *));
+extern	int	write_secs(SCSI *scgp, cdr_t *dp, char *bp, long startsec, 
+								  int bytespt, int secspt, BOOL islast);
+extern	int	pad_track(SCSI *scgp, cdr_t *dp, track_t *trackp,
+								 long startsec, Llong amt,
+								 BOOL dolast, Llong *bytesp);
+extern	void	load_media(SCSI *scgp, cdr_t *, BOOL);
+extern	void	unload_media(SCSI *scgp, cdr_t *, int);
+extern	void	reload_media(SCSI *scgp, cdr_t *);
 #endif
-extern	void	raisepri	__PR((int));
-extern	int	getnum		__PR((char *arg, long *valp));
+extern	void	raisepri(int);
+extern	int	getnum(char *arg, long *valp);
 
 /*
  * cd_misc.c
  */
-extern	int	from_bcd	__PR((int b));
-extern	int	to_bcd		__PR((int i));
-extern	long	msf_to_lba	__PR((int m, int s, int f, BOOL force_positive));
-extern	BOOL	lba_to_msf	__PR((long lba, msf_t *mp));
-extern	void	sec_to_msf	__PR((long sec, msf_t *mp));
-extern	void	print_min_atip	__PR((long li, long lo));
+extern	int	from_bcd(int b);
+extern	int	to_bcd(int i);
+extern	long	msf_to_lba(int m, int s, int f, BOOL force_positive);
+extern	BOOL	lba_to_msf(long lba, msf_t *mp);
+extern	void	sec_to_msf(long sec, msf_t *mp);
+extern	void	print_min_atip(long li, long lo);
 
 /*
  * fifo.c
  */
-extern	void	init_fifo	__PR((long));
-extern	BOOL	init_faio	__PR((track_t *track, int));
-extern	BOOL	await_faio	__PR((void));
-extern	void	kill_faio	__PR((void));
-extern	int	wait_faio	__PR((void));
-extern	int	faio_read_buf	__PR((int f, char *bp, int size));
-extern	int	faio_get_buf	__PR((int f, char **bpp, int size));
-extern	void	fifo_stats	__PR((void));
-extern	int	fifo_percent	__PR((BOOL addone));
+extern	void	init_fifo(long);
+extern	BOOL	init_faio(track_t *track, int);
+extern	BOOL	await_faio(void);
+extern	void	kill_faio(void);
+extern	int	wait_faio(void);
+extern	int	faio_read_buf(int f, char *bp, int size);
+extern	int	faio_get_buf(int f, char **bpp, int size);
+extern	void	fifo_stats(void);
+extern	int	fifo_percent(BOOL addone);
 
 /*
  * wm_session.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	write_session_data __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
+extern	int	write_session_data(SCSI *scgp, cdr_t *dp, track_t *trackp);
 #endif
 
 /*
@@ -872,90 +905,93 @@
  * wm_packet.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	write_packet_data __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
+extern	int	write_packet_data(SCSI *scgp, cdr_t *dp, track_t *trackp);
 #endif
 
 /*
  * modes.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	BOOL	get_mode_params	__PR((SCSI *scgp, int page, char *pagename,
-					Uchar *modep, Uchar *cmodep,
-					Uchar *dmodep, Uchar *smodep,
-					int *lenp));
-extern	BOOL	set_mode_params	__PR((SCSI *scgp, char *pagename, Uchar *modep,
-					int len, int save, int secsize));
+extern	BOOL	get_mode_params(SCSI *scgp, int page, char *pagename,
+										 Uchar *modep, Uchar *cmodep,
+										 Uchar *dmodep, Uchar *smodep,
+										 int *lenp);
+extern	BOOL	set_mode_params(SCSI *scgp, char *pagename, Uchar *modep,
+										 int len, int save, int secsize);
 #endif
 
 /*
  * misc.c
  */
 #ifdef	timerclear
-extern	void	timevaldiff	__PR((struct timeval *start, struct timeval *stop));
-extern	void	prtimediff	__PR((const char *fmt,
-					struct timeval *start,
-					struct timeval *stop));
+extern	void	timevaldiff(struct timeval *start, struct timeval *stop);
+extern	void	prtimediff(const char *fmt, struct timeval *start,
+								  struct timeval *stop);
 #endif
 
 /*
  * getnum.c
  */
-extern	int	getnum		__PR((char *arg, long *valp));
-extern	int	getllnum	__PR((char *arg, Llong *lvalp));
+extern	int	getnum(char *arg, long *valp);
+extern	int	getllnum(char *arg, Llong *lvalp);
 
 /*
  * scsi_cdr.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	BOOL	unit_ready	__PR((SCSI *scgp));
-extern	BOOL	wait_unit_ready	__PR((SCSI *scgp, int secs));
-extern	BOOL	scsi_in_progress __PR((SCSI *scgp));
-extern	BOOL	cdr_underrun	__PR((SCSI *scgp));
-extern	int	test_unit_ready	__PR((SCSI *scgp));
-extern	int	rezero_unit	__PR((SCSI *scgp));
-extern	int	request_sense	__PR((SCSI *scgp));
-extern	int	request_sense_b	__PR((SCSI *scgp, caddr_t bp, int cnt));
-extern	int	inquiry		__PR((SCSI *scgp, caddr_t, int));
-extern	int	read_capacity	__PR((SCSI *scgp));
+extern	BOOL	unit_ready(SCSI *scgp);
+extern	BOOL	wait_unit_ready(SCSI *scgp, int secs);
+extern	BOOL	scsi_in_progress(SCSI *scgp);
+extern	BOOL	cdr_underrun(SCSI *scgp);
+extern	int	test_unit_ready(SCSI *scgp);
+extern	int	rezero_unit(SCSI *scgp);
+extern	int	request_sense(SCSI *scgp);
+extern	int	request_sense_b(SCSI *scgp, caddr_t bp, int cnt);
+extern	int	inquiry(SCSI *scgp, caddr_t, int);
+extern	int	read_capacity(SCSI *scgp);
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	print_capacity	__PR((SCSI *scgp, FILE *f));
+extern	void	print_capacity(SCSI *scgp, FILE *f);
 #endif
-extern	int	scsi_load_unload __PR((SCSI *scgp, int));
-extern	int	scsi_prevent_removal __PR((SCSI *scgp, int));
-extern	int	scsi_start_stop_unit __PR((SCSI *scgp, int, int, BOOL immed));
+extern	int	scsi_load_unload(SCSI *scgp, int);
+extern	int	scsi_prevent_removal(SCSI *scgp, int);
+extern	int	scsi_start_stop_unit(SCSI *scgp, int, int, BOOL immed);
 
 #define	ROTCTL_CLV	0	/* CLV or PCAV	*/
 #define	ROTCTL_CAV	1	/* True CAV	*/
 
-extern	int	scsi_set_speed	__PR((SCSI *scgp, int readspeed, int writespeed, int rotctl));
-extern	int	scsi_get_speed	__PR((SCSI *scgp, int *readspeedp, int *writespeedp));
-extern	int	qic02		__PR((SCSI *scgp, int));
-extern	int	write_xscsi	__PR((SCSI *scgp, caddr_t, long, long, int));
-extern	int	write_xg0	__PR((SCSI *scgp, caddr_t, long, long, int));
-extern	int	write_xg1	__PR((SCSI *scgp, caddr_t, long, long, int));
-extern	int	write_xg5	__PR((SCSI *scgp, caddr_t, long, long, int));
-extern	int	seek_scsi	__PR((SCSI *scgp, long addr));
-extern	int	seek_g0		__PR((SCSI *scgp, long addr));
-extern	int	seek_g1		__PR((SCSI *scgp, long addr));
-extern	int	scsi_flush_cache __PR((SCSI *scgp, BOOL immed));
-extern	int	read_buffer	__PR((SCSI *scgp, caddr_t bp, int cnt, int mode));
-extern	int	write_buffer	__PR((SCSI *scgp, char *buffer, long length, int mode, int bufferid, long offset));
-extern	int	read_subchannel	__PR((SCSI *scgp, caddr_t bp, int track,
-					int cnt, int msf, int subq, int fmt));
-extern	int	read_toc	__PR((SCSI *scgp, caddr_t, int, int, int, int));
-extern	int	read_toc_philips __PR((SCSI *scgp, caddr_t, int, int, int, int));
-extern	int	read_header	__PR((SCSI *scgp, caddr_t, long, int, int));
-extern	int	read_disk_info	__PR((SCSI *scgp, caddr_t, int));
+extern	int	scsi_set_speed(SCSI *scgp, int readspeed, int writespeed, 
+										int rotctl);
+extern	int	scsi_get_speed(SCSI *scgp, int *readspeedp, int *writespeedp);
+extern	int	qic02(SCSI *scgp, int);
+extern	int	write_xscsi(SCSI *scgp, caddr_t, long, long, int);
+extern	int	write_xg0(SCSI *scgp, caddr_t, long, long, int);
+extern	int	write_xg1(SCSI *scgp, caddr_t, long, long, int);
+extern	int	write_xg5(SCSI *scgp, caddr_t, long, long, int);
+extern	int	seek_scsi(SCSI *scgp, long addr);
+extern	int	seek_g0(SCSI *scgp, long addr);
+extern	int	seek_g1(SCSI *scgp, long addr);
+extern	int	scsi_flush_cache(SCSI *scgp, BOOL immed);
+extern	int	read_buffer(SCSI *scgp, caddr_t bp, int cnt, int mode);
+extern	int	write_buffer(SCSI *scgp, char *buffer, long length, int mode, 
+									 int bufferid, long offset);
+extern	int	read_subchannel(SCSI *scgp, caddr_t bp, int track, int cnt, 
+										 int msf, int subq, int fmt);
+extern	int	read_toc(SCSI *scgp, caddr_t, int, int, int, int);
+extern	int	read_toc_philips(SCSI *scgp, caddr_t, int, int, int, int);
+extern	int	read_header(SCSI *scgp, caddr_t, long, int, int);
+extern	int	read_disk_info(SCSI *scgp, caddr_t, int);
 
 #define	TI_TYPE_LBA	0	/* Address is LBA */
 #define	TI_TYPE_TRACK	1	/* Address: 0 -> TOC, xx -> Track xx, 0xFF -> Inv Track */
 #define	TI_TYPE_SESS	2	/* Address is session # */
-extern	int	read_track_info	__PR((SCSI *scgp, caddr_t, int type, int addr, int cnt));
-extern	int	read_rzone_info	__PR((SCSI *scgp, caddr_t bp, int cnt));
-extern	int	reserve_tr_rzone __PR((SCSI *scgp, long size));
-extern	int	read_dvd_structure __PR((SCSI *scgp, caddr_t bp, int cnt, int addr, int layer, int fmt));
-extern	int	send_dvd_structure __PR((SCSI *scgp, caddr_t bp, int cnt, int layer, int fmt));
-extern	int	send_opc	__PR((SCSI *scgp, caddr_t, int cnt, int doopc));
+extern	int	read_track_info(SCSI *scgp, caddr_t, int type, int addr, int cnt);
+extern	int	read_rzone_info(SCSI *scgp, caddr_t bp, int cnt);
+extern	int	reserve_tr_rzone(SCSI *scgp, long size);
+extern	int	read_dvd_structure(SCSI *scgp, caddr_t bp, int cnt, int addr, 
+											 int layer, int fmt);
+extern	int	send_dvd_structure(SCSI *scgp, caddr_t bp, int cnt, int layer, 
+											 int fmt);
+extern	int	send_opc(SCSI *scgp, caddr_t, int cnt, int doopc);
 
 #define	CL_TYPE_STOP_DEICE	0	/* Stop De-icing a DVD+RW Media */
 #define	CL_TYPE_TRACK		1	/* Close Track # */
@@ -964,87 +1000,88 @@
 #define	CL_TYPE_OPEN_SESSION	4	/* Close the Open Session and Record an Extended lead-out */
 #define	CL_TYPE_FINALISE_MINRAD	5	/* Finalize the Disc with a Minimum Recorded Radius */
 #define	CL_TYPE_FINALISE	6	/* Finalize the disc */
-extern	int	scsi_close_tr_session __PR((SCSI *scgp, int type, int track, BOOL immed));
-extern	int	read_master_cue	__PR((SCSI *scgp, caddr_t bp, int sheet, int cnt));
-extern	int	send_cue_sheet	__PR((SCSI *scgp, caddr_t bp, long size));
-extern	int	read_buff_cap	__PR((SCSI *scgp, long *, long *));
-extern	int	scsi_blank	__PR((SCSI *scgp, long addr, int blanktype, BOOL immed));
-extern	BOOL	allow_atapi	__PR((SCSI *scgp, BOOL new));
-extern	int	mode_select	__PR((SCSI *scgp, Uchar *, int, int, int));
-extern	int	mode_sense	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-extern	int	mode_select_sg0	__PR((SCSI *scgp, Uchar *, int, int, int));
-extern	int	mode_sense_sg0	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-extern	int	mode_select_g0	__PR((SCSI *scgp, Uchar *, int, int, int));
-extern	int	mode_select_g1	__PR((SCSI *scgp, Uchar *, int, int, int));
-extern	int	mode_sense_g0	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-extern	int	mode_sense_g1	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-extern	int	read_tochdr	__PR((SCSI *scgp, cdr_t *, int *, int *));
-extern	int	read_cdtext	__PR((SCSI *scgp));
-extern	int	read_trackinfo	__PR((SCSI *scgp, int, long *, struct msf *, int *, int *, int *));
-extern	int	read_B0		__PR((SCSI *scgp, BOOL isbcd, long *b0p, long *lop));
-extern	int	read_session_offset __PR((SCSI *scgp, long *));
-extern	int	read_session_offset_philips __PR((SCSI *scgp, long *));
-extern	int	sense_secsize	__PR((SCSI *scgp, int current));
-extern	int	select_secsize	__PR((SCSI *scgp, int));
-extern	BOOL	is_cddrive	__PR((SCSI *scgp));
-extern	BOOL	is_unknown_dev	__PR((SCSI *scgp));
-extern	int	read_scsi	__PR((SCSI *scgp, caddr_t, long, int));
-extern	int	read_g0		__PR((SCSI *scgp, caddr_t, long, int));
-extern	int	read_g1		__PR((SCSI *scgp, caddr_t, long, int));
-extern	BOOL	getdev		__PR((SCSI *scgp, BOOL));
+extern	int	scsi_close_tr_session(SCSI *scgp, int type, int track, 
+												 BOOL immed);
+extern	int	read_master_cue(SCSI *scgp, caddr_t bp, int sheet, int cnt);
+extern	int	send_cue_sheet(SCSI *scgp, caddr_t bp, long size);
+extern	int	read_buff_cap(SCSI *scgp, long *, long *);
+extern	int	scsi_blank(SCSI *scgp, long addr, int blanktype, BOOL immed);
+extern	BOOL	allow_atapi(SCSI *scgp, BOOL new);
+extern	int	mode_select(SCSI *scgp, Uchar *, int, int, int);
+extern	int	mode_sense(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+extern	int	mode_select_sg0(SCSI *scgp, Uchar *, int, int, int);
+extern	int	mode_sense_sg0(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+extern	int	mode_select_g0(SCSI *scgp, Uchar *, int, int, int);
+extern	int	mode_select_g1(SCSI *scgp, Uchar *, int, int, int);
+extern	int	mode_sense_g0(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+extern	int	mode_sense_g1(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+extern	int	read_tochdr(SCSI *scgp, cdr_t *, int *, int *);
+extern	int	read_cdtext(SCSI *scgp);
+extern	int	read_trackinfo(SCSI *scgp, int, long *, struct msf *, int *, 
+										int *, int *);
+extern	int	read_B0(SCSI *scgp, BOOL isbcd, long *b0p, long *lop);
+extern	int	read_session_offset(SCSI *scgp, long *);
+extern	int	read_session_offset_philips(SCSI *scgp, long *);
+extern	int	sense_secsize(SCSI *scgp, int current);
+extern	int	select_secsize(SCSI *scgp, int);
+extern	BOOL	is_cddrive(SCSI *scgp);
+extern	BOOL	is_unknown_dev(SCSI *scgp);
+extern	int	read_scsi(SCSI *scgp, caddr_t, long, int);
+extern	int	read_g0(SCSI *scgp, caddr_t, long, int);
+extern	int	read_g1(SCSI *scgp, caddr_t, long, int);
+extern	BOOL	getdev(SCSI *scgp, BOOL);
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	printinq	__PR((SCSI *scgp, FILE *f));
+extern	void	printinq(SCSI *scgp, FILE *f);
 #endif
-extern	void	printdev	__PR((SCSI *scgp));
-extern	BOOL	do_inquiry	__PR((SCSI *scgp, BOOL));
-extern	BOOL	recovery_needed	__PR((SCSI *scgp, cdr_t *));
-extern	int	scsi_load	__PR((SCSI *scgp, cdr_t *));
-extern	int	scsi_unload	__PR((SCSI *scgp, cdr_t *));
-extern	int	scsi_cdr_write	__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-extern	struct cd_mode_page_2A * mmc_cap __PR((SCSI *scgp, Uchar *modep));
-extern	void	mmc_getval	__PR((struct cd_mode_page_2A *mp,
-					BOOL *cdrrp, BOOL *cdwrp,
-					BOOL *cdrrwp, BOOL *cdwrwp,
-					BOOL *dvdp, BOOL *dvdwp));
-extern	BOOL	is_mmc		__PR((SCSI *scgp, BOOL *cdwp, BOOL *dvdwp));
-extern	BOOL	mmc_check	__PR((SCSI *scgp, BOOL *cdrrp, BOOL *cdwrp,
-					BOOL *cdrrwp, BOOL *cdwrwp,
-					BOOL *dvdp, BOOL *dvdwp));
-extern	void	print_capabilities	__PR((SCSI *scgp));
+extern	void	printdev(SCSI *scgp);
+extern	BOOL	do_inquiry(SCSI *scgp, BOOL);
+extern	BOOL	recovery_needed(SCSI *scgp, cdr_t *);
+extern	int	scsi_load(SCSI *scgp, cdr_t *);
+extern	int	scsi_unload(SCSI *scgp, cdr_t *);
+extern	int	scsi_cdr_write(SCSI *scgp, caddr_t bp, long sectaddr, 
+										long size, int blocks, BOOL islast);
+extern	struct cd_mode_page_2A *mmc_cap(SCSI *scgp, Uchar *modep);
+extern	void	mmc_getval(struct cd_mode_page_2A *mp, BOOL *cdrrp, BOOL *cdwrp,
+								  BOOL *cdrrwp, BOOL *cdwrwp, BOOL *dvdp, BOOL *dvdwp);
+extern	BOOL	is_mmc(SCSI *scgp, BOOL *cdwp, BOOL *dvdwp);
+extern	BOOL	mmc_check(SCSI *scgp, BOOL *cdrrp, BOOL *cdwrp, BOOL *cdrrwp, 
+								 BOOL *cdwrwp, BOOL *dvdp, BOOL *dvdwp);
+extern	void	print_capabilities(SCSI *scgp);
 #endif
 
 /*
  * scsi_cdr.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	void	print_capabilities_mmc4	__PR((SCSI *scgp));
+extern	void	print_capabilities_mmc4(SCSI *scgp);
 #endif
 
 /*
  * scsi_mmc.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	get_configuration	__PR((SCSI *scgp, caddr_t bp, int cnt, int st_feature, int rt));
-extern	int	get_curprofile		__PR((SCSI *scgp));
-extern	int	print_profiles		__PR((SCSI *scgp));
-extern	int	get_proflist		__PR((SCSI *scgp, BOOL *wp, BOOL *cdp, BOOL *dvdp,
-							BOOL *dvdplusp, BOOL *ddcdp));
-extern	int	get_wproflist		__PR((SCSI *scgp, BOOL *cdp, BOOL *dvdp,
-							BOOL *dvdplusp, BOOL *ddcdp));
+extern	int	get_configuration(SCSI *scgp, caddr_t bp, int cnt, 
+											int st_feature, int rt);
+extern	int	get_curprofile(SCSI *scgp);
+extern	int	print_profiles(SCSI *scgp);
+extern	int	get_proflist(SCSI *scgp, BOOL *wp, BOOL *cdp, BOOL *dvdp,
+									 BOOL *dvdplusp, BOOL *ddcdp);
+extern	int	get_wproflist(SCSI *scgp, BOOL *cdp, BOOL *dvdp,
+									  BOOL *dvdplusp, BOOL *ddcdp);
 #endif
 
 /*
  * scsi_mmc.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	get_supported_cdrw_media_types	__PR((SCSI *scgp));
+extern	int	get_supported_cdrw_media_types(SCSI *scgp);
 #endif
 
 /*
  * mmc_misc.c
  */
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	check_writemodes_mmc	__PR((SCSI *scgp, cdr_t *dp));
+extern	int	check_writemodes_mmc(SCSI *scgp, cdr_t *dp);
 #endif	/* _SCG_SCSITRANSP_H */
 
 /*
@@ -1052,68 +1089,68 @@
  */
 #ifdef	_SCG_SCSITRANSP_H
 #ifdef	_SCG_SCSIREG_H
-extern	cdr_t	*drive_identify		__PR((SCSI *scgp, cdr_t *, struct scsi_inquiry *ip));
+extern	cdr_t	*drive_identify(SCSI *scgp, cdr_t *, struct scsi_inquiry *ip);
 #else
-extern	cdr_t	*drive_identify		__PR((SCSI *scgp, cdr_t *, void *ip));
+extern	cdr_t	*drive_identify(SCSI *scgp, cdr_t *, void *ip);
 #endif
-extern	int	drive_attach		__PR((SCSI *scgp, cdr_t *));
+extern	int	drive_attach(SCSI *scgp, cdr_t *);
 #endif
-extern	int	attach_unknown		__PR((void));
+extern	int	attach_unknown(void);
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	blank_dummy		__PR((SCSI *scgp, cdr_t *, long addr, int blanktype));
-int	format_dummy		__PR((SCSI *scgp, cdr_t *, int fmtflags));
-extern	int	drive_getdisktype	__PR((SCSI *scgp, cdr_t *dp));
-extern	int	cmd_ill			__PR((SCSI *scgp));
-extern	int	cmd_dummy		__PR((SCSI *scgp, cdr_t *));
-extern	int	no_sendcue		__PR((SCSI *scgp, cdr_t *, track_t *trackp));
-extern	int	buf_dummy		__PR((SCSI *scgp, long *sp, long *fp));
+extern	int	blank_dummy(SCSI *scgp, cdr_t *, long addr, int blanktype);
+int	format_dummy(SCSI *scgp, cdr_t *, int fmtflags);
+extern	int	drive_getdisktype(SCSI *scgp, cdr_t *dp);
+extern	int	cmd_ill(SCSI *scgp);
+extern	int	cmd_dummy(SCSI *scgp, cdr_t *);
+extern	int	no_sendcue(SCSI *scgp, cdr_t *, track_t *trackp);
+extern	int	buf_dummy(SCSI *scgp, long *sp, long *fp);
 #endif
-extern	BOOL	set_cdrcmds		__PR((char *name, cdr_t **dpp));
+extern	BOOL	set_cdrcmds(char *name, cdr_t **dpp);
 #ifdef	_SCG_SCSITRANSP_H
-extern	cdr_t	*get_cdrcmds		__PR((SCSI *scgp));
+extern	cdr_t	*get_cdrcmds(SCSI *scgp);
 #endif
 
 
 /*
  * drv_mmc.c
  */
-extern	void	mmc_opthelp		__PR((cdr_t *dp, int excode));
-extern	char	*hasdrvopt		__PR((char *optstr, char *optname));
+extern	void	mmc_opthelp(cdr_t *dp, int excode);
+extern	char	*hasdrvopt(char *optstr, char *optname);
 #ifdef	_SCG_SCSITRANSP_H
-extern struct ricoh_mode_page_30 * get_justlink_ricoh	__PR((SCSI *scgp, Uchar *mode));
+extern struct ricoh_mode_page_30 *get_justlink_ricoh(SCSI *scgp, Uchar *mode);
 #endif
 
 /*
  * isosize.c
  */
-extern	Llong	isosize		__PR((int f));
+extern	Llong	isosize(int f);
 
 /*
  * audiosize.c
  */
-extern	BOOL	is_auname	__PR((const char *name));
-extern	off_t	ausize		__PR((int f));
-extern	BOOL	is_wavname	__PR((const char *name));
-extern	off_t	wavsize		__PR((int f));
+extern	BOOL	is_auname(const char *name);
+extern	off_t	ausize(int f);
+extern	BOOL	is_wavname(const char *name);
+extern	off_t	wavsize(int f);
 
 /*
  * auinfo.c
  */
-extern	BOOL	auinfosize	__PR((char *name, track_t *trackp));
-extern	void	auinfo		__PR((char *name, int track, track_t *trackp));
+extern	BOOL	auinfosize(char *name, track_t *trackp);
+extern	void	auinfo(char *name, int track, track_t *trackp);
 #ifdef CDTEXT_H
-extern	textptr_t *gettextptr	__PR((int track, track_t *trackp));
+extern	textptr_t *gettextptr(int track, track_t *trackp);
 #endif
-extern	void	setmcn		__PR((char *mcn, track_t *trackp));
-extern	void	setisrc		__PR((char *isrc, track_t *trackp));
-extern	void	setindex	__PR((char *tindex, track_t *trackp));
+extern	void	setmcn(char *mcn, track_t *trackp);
+extern	void	setisrc(char *isrc, track_t *trackp);
+extern	void	setindex(char *tindex, track_t *trackp);
 
 /*
  * diskid.c
  */
-extern	void	pr_manufacturer		__PR((msf_t *mp, BOOL rw, BOOL audio));
-extern	int	manufacturer_id		__PR((msf_t *mp));
-extern	long	disk_rcap		__PR((msf_t *mp, long maxblock, BOOL rw, BOOL audio));
+extern	void	pr_manufacturer(msf_t *mp, BOOL rw, BOOL audio);
+extern	int	manufacturer_id(msf_t *mp);
+extern	long	disk_rcap(msf_t *mp, long maxblock, BOOL rw, BOOL audio);
 
 /*--------------------------------------------------------------------------*/
 /* Test only								    */
@@ -1127,47 +1164,48 @@
 /*
  * subchan.c
  */
-extern	int	do_leadin	__PR((track_t *trackp));
+extern	int	do_leadin(track_t *trackp);
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	write_leadin	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp, int leadinstart));
-extern	int	write_leadout	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
+extern	int	write_leadin(SCSI *scgp, cdr_t *dp, track_t *trackp, 
+									 int leadinstart);
+extern	int	write_leadout(SCSI *scgp, cdr_t *dp, track_t *trackp);
 #endif
-extern	void	fillsubch	__PR((track_t *trackp, Uchar *sp, int secno, int nsecs));
-extern	void	filltpoint	__PR((Uchar *sub, int ctrl_adr, int point, msf_t *mp));
-extern	void	fillttime	__PR((Uchar *sub, msf_t *mp));
-extern	void	qpto96		__PR((Uchar *sub, Uchar *subq, int dop));
-extern	void	addrw		__PR((Uchar *sub, Uchar	*subrwptr));
-extern	void	qwto16		__PR((Uchar *subq, Uchar *subptr));
-extern	void	subrecodesecs	__PR((track_t *trackp, Uchar *bp, int address, int nsecs));
+extern	void	fillsubch(track_t *trackp, Uchar *sp, int secno, int nsecs);
+extern	void	filltpoint(Uchar *sub, int ctrl_adr, int point, msf_t *mp);
+extern	void	fillttime(Uchar *sub, msf_t *mp);
+extern	void	qpto96(Uchar *sub, Uchar *subq, int dop);
+extern	void	addrw(Uchar *sub, Uchar	*subrwptr);
+extern	void	qwto16(Uchar *subq, Uchar *subptr);
+extern	void	subrecodesecs(track_t *trackp, Uchar *bp, int address, int nsecs);
 
 /*
  * sector.c
  */
-extern	int	encspeed	__PR((BOOL be_verbose));
-extern	void	encsectors	__PR((track_t *trackp, Uchar *bp, int address, int nsecs));
-extern	void	scrsectors	__PR((track_t *trackp, Uchar *bp, int address, int nsecs));
-extern	void	encodesector	__PR((Uchar *sp, int sectype, int address));
-extern	void	fillsector	__PR((Uchar *sp, int sectype, int address));
+extern	int	encspeed(BOOL be_verbose);
+extern	void	encsectors(track_t *trackp, Uchar *bp, int address, int nsecs);
+extern	void	scrsectors(track_t *trackp, Uchar *bp, int address, int nsecs);
+extern	void	encodesector(Uchar *sp, int sectype, int address);
+extern	void	fillsector(Uchar *sp, int sectype, int address);
 
 /*
  * clone.c
  */
-extern	void	clone_toc	__PR((track_t *trackp));
-extern	void	clone_tracktype	__PR((track_t *trackp));
+extern	void	clone_toc(track_t *trackp);
+extern	void	clone_tracktype(track_t *trackp);
 
 /*
  * cdtext.c
  */
-extern	BOOL	checktextfile	__PR((char *fname));
-extern	void	packtext	__PR((int tracks, track_t *trackp));
+extern	BOOL	checktextfile(char *fname);
+extern	void	packtext(int tracks, track_t *trackp);
 #ifdef	_SCG_SCSITRANSP_H
-extern	int	write_cdtext	__PR((SCSI *scgp, cdr_t *dp, long startsec));
+extern	int	write_cdtext(SCSI *scgp, cdr_t *dp, long startsec);
 #endif
 
 /*
  * cue.c
  */
-extern	int	parsecue	__PR((char *cuefname, track_t trackp[]));
+extern	int	parsecue(char *cuefname, track_t trackp[]);
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	fparsecue	__PR((FILE *f, track_t trackp[]));
+extern	void	fparsecue(FILE *f, track_t trackp[]);
 #endif

Modified: nonameyet/branches/cleanup/cdrecord/cdtext.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/cdtext.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/cdtext.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -120,20 +120,19 @@
 Uchar	*textsub;
 int	textlen;
 
-BOOL	checktextfile	__PR((char *fname));
-static	void	setuptextdata	__PR((Uchar *bp, int len));
-static	BOOL	cdtext_crc_ok	__PR((struct textpack *p));
-void	packtext	__PR((int tracks, track_t *trackp));
-static	BOOL	anytext		__PR((int pack_type, int tracks, track_t *trackp));
-static	void	fillup_pack	__PR((txtarg_t *ap));
-static	void	fillpacks	__PR((txtarg_t *ap, char *from, int len, int track_no, int pack_type));
-int	write_cdtext	__PR((SCSI *scgp, cdr_t *dp, long startsec));
-static	void	eight2six	__PR((Uchar *in, Uchar *out));
-static	void	six2eight	__PR((Uchar *in, Uchar *out));
+BOOL			checktextfile(char *fname);
+static void	setuptextdata(Uchar *bp, int len);
+static BOOL	cdtext_crc_ok(struct textpack *p);
+void			packtext(int tracks, track_t *trackp);
+static BOOL	anytext(int pack_type, int tracks, track_t *trackp);
+static void	fillup_pack(txtarg_t *ap);
+static void	fillpacks(txtarg_t *ap, char *from, int len, int track_no, int pack_type);
+int			write_cdtext(SCSI *scgp, cdr_t *dp, long startsec);
+static void	eight2six(Uchar *in, Uchar *out);
+static void	six2eight(Uchar *in, Uchar *out);
 
 
-BOOL
-checktextfile(char *fname)
+BOOL checktextfile(char *fname)
 {
 	FILE	*f;
 	Uchar	hbuf[4];
@@ -214,8 +213,7 @@
 	return (TRUE);
 }
 
-static void
-setuptextdata(Uchar *bp, int len)
+static void setuptextdata(Uchar *bp, int len)
 {
 	int	n;
 	int	i;
@@ -282,8 +280,7 @@
 #endif
 }
 
-static BOOL
-cdtext_crc_ok(struct textpack *p)
+static BOOL cdtext_crc_ok(struct textpack *p)
 {
 	int		crc;
 	struct textpack	new;
@@ -302,8 +299,7 @@
 }
 
 
-void
-packtext(int tracks, track_t *trackp)
+void packtext(int tracks, track_t *trackp)
 {
 	int	type;
 	int	i;
@@ -381,8 +377,7 @@
 #endif
 }
 
-static BOOL
-anytext(int pack_type, int tracks, track_t *trackp)
+static BOOL anytext(int pack_type, int tracks, track_t *trackp)
 {
 	register int	i;
 	register char	*p;
@@ -397,8 +392,7 @@
 	return (FALSE);
 }
 
-static void
-fillup_pack(register txtarg_t *ap)
+static void fillup_pack(register txtarg_t *ap)
 {
 	if (ap->p) {
 		fillbytes(ap->p, &ap->tp->text[12] - ap->p, '\0');
@@ -408,9 +402,8 @@
 	}
 }
 
-static void
-fillpacks(register txtarg_t *ap, register char *from, int len, 
-          int track_no, int pack_type)
+static void fillpacks(register txtarg_t *ap, register char *from, int len, 
+          				 int track_no, int pack_type)
 {
 	register int		charpos;
 	register char		*p;
@@ -448,8 +441,7 @@
 	ap->p = p;
 }
 
-int
-write_cdtext(SCSI *scgp, cdr_t *dp, long startsec)
+int write_cdtext(SCSI *scgp, cdr_t *dp, long startsec)
 {
 	char	*bp = (char *)textsub;
 	int	buflen = textlen;
@@ -518,8 +510,7 @@
 /*
  * 3 input bytes (8 bit based) are converted into 4 output bytes (6 bit based).
  */
-static void
-eight2six(register Uchar *in, register Uchar *out)
+static void eight2six(register Uchar *in, register Uchar *out)
 {
 	register int	c;
 
@@ -539,8 +530,7 @@
 /*
  * 4 input bytes (6 bit based) are converted into 3 output bytes (8 bit based).
  */
-static void
-six2eight(register Uchar *in, register Uchar *out)
+static void six2eight(register Uchar *in, register Uchar *out)
 {
 	register int	c;
 

Modified: nonameyet/branches/cleanup/cdrecord/clone.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/clone.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/clone.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -56,8 +56,8 @@
 
 /*#define	SAO_RAW*/
 
-void	clone_toc	__PR((track_t *trackp));
-void	clone_tracktype	__PR((track_t *trackp));
+void	clone_toc(track_t *trackp);
+void	clone_tracktype(track_t *trackp);
 
 extern	int	lverbose;
 extern	int	xdebug;
@@ -76,8 +76,7 @@
 /*
  * Read Clone TOC description from full toc file.
  */
-void
-clone_toc(track_t *trackp)
+void clone_toc(track_t *trackp)
 {
 	char	filename[1024];
 	msf_t	m;
@@ -213,8 +212,7 @@
  * Control 4 = data
  * Control 5 = packet data
  */
-void
-clone_tracktype(track_t *trackp)
+void clone_tracktype(track_t *trackp)
 {
 	int	tracks = trackp->tracks;
 	int	sectype;

Modified: nonameyet/branches/cleanup/cdrecord/crc16.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/crc16.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/crc16.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -44,11 +44,10 @@
 #include <utypes.h>
 #include "crc16.h"
 
-static	UInt16_t	updcrc		__PR((Uint p_crc, UInt8_t *cp, Uint cnt));
-/*static	UInt16_t	calcCRC		__PR((Uchar *buf, Uint bsize));*/
-UInt16_t	calcCRC		__PR((Uchar *buf, Uint bsize));
-UInt16_t	fillcrc		__PR((Uchar *buf, Uint bsize));
-UInt16_t	flip_crc_error_corr	__PR((Uchar *b, Uint bsize, Uint p_crc));
+static	UInt16_t	updcrc(Uint p_crc, UInt8_t *cp, Uint cnt);
+UInt16_t	calcCRC(Uchar *buf, Uint bsize);
+UInt16_t	fillcrc(Uchar *buf, Uint bsize);
+UInt16_t	flip_crc_error_corr(Uchar *b, Uint bsize, Uint p_crc);
 
 
 	/* number of bits in CRC: don't change it. */
@@ -94,7 +93,7 @@
 
 #define	SUBSIZE	96	/* 12 bytes with 8 bits */
 
-static UInt16_t
+static UInt16_t 
 updcrc(Uint p_crc, register UInt8_t *cp, register Uint cnt)
 {
 	register UInt16_t	crc = p_crc;
@@ -106,7 +105,7 @@
 }
 
 /*static UInt16_t*/
-UInt16_t
+UInt16_t 
 calcCRC(Uchar *buf, Uint bsize)
 {
 	return (updcrc(0x0000, (UInt8_t *)buf, bsize));
@@ -115,7 +114,7 @@
 /*
  * CRC für Q-Sub füllen
  */
-UInt16_t
+UInt16_t 
 fillcrc(Uchar *buf, Uint bsize)
 {
 	UInt16_t	crc = calcCRC(buf, bsize-2);
@@ -141,7 +140,7 @@
 	0x80,
 };
 
-UInt16_t
+UInt16_t 
 flip_crc_error_corr(Uchar *b, Uint bsize, Uint p_crc)
 {
 	register UInt16_t	crc = p_crc;

Modified: nonameyet/branches/cleanup/cdrecord/crc16.h
===================================================================
--- nonameyet/branches/cleanup/cdrecord/crc16.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/crc16.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -34,8 +34,8 @@
 #ifndef	_CRC16_H
 #define	_CRC16_H
 
-extern	UInt16_t	calcCRC		__PR((Uchar *buf, Uint bsize));
-extern	UInt16_t	fillcrc		__PR((Uchar *buf, Uint bsize));
-extern	UInt16_t	flip_crc_error_corr __PR((Uchar *b, Uint bsize, Uint p_crc));
+extern	UInt16_t	calcCRC(Uchar *buf, Uint bsize);
+extern	UInt16_t	fillcrc(Uchar *buf, Uint bsize);
+extern	UInt16_t	flip_crc_error_corr(Uchar *b, Uint bsize, Uint p_crc);
 
 #endif

Modified: nonameyet/branches/cleanup/cdrecord/cue.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/cue.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/cue.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -230,55 +230,52 @@
 };
 
 
-#ifdef	CUE_MAIN
-int	main		__PR((int ac, char **av));
-#endif
-int	parsecue	__PR((char *cuefname, track_t trackp[]));
-void	fparsecue	__PR((FILE *f, track_t trackp[]));
-static	void	parse_mcn	__PR((track_t trackp[], state_t *sp));
-static	void	parse_textfile	__PR((track_t trackp[], state_t *sp));
-static	void	parse_file	__PR((track_t trackp[], state_t *sp));
-static	void	parse_flags	__PR((track_t trackp[], state_t *sp));
-static	void	parse_index	__PR((track_t trackp[], state_t *sp));
-static	void	parse_isrc	__PR((track_t trackp[], state_t *sp));
-static	void	parse_performer	__PR((track_t trackp[], state_t *sp));
-static	void	parse_postgap	__PR((track_t trackp[], state_t *sp));
-static	void	parse_pregap	__PR((track_t trackp[], state_t *sp));
-static	void	parse_songwriter __PR((track_t trackp[], state_t *sp));
-static	void	parse_title	__PR((track_t trackp[], state_t *sp));
-static	void	parse_track	__PR((track_t trackp[], state_t *sp));
-static	void	parse_offset	__PR((long *lp));
-static	void	newtrack	__PR((track_t trackp[], state_t *sp));
+int	parsecue(char *cuefname, track_t trackp[]);
+void	fparsecue(FILE *f, track_t trackp[]);
+static	void	parse_mcn(track_t trackp[], state_t *sp);
+static	void	parse_textfile(track_t trackp[], state_t *sp);
+static	void	parse_file(track_t trackp[], state_t *sp);
+static	void	parse_flags(track_t trackp[], state_t *sp);
+static	void	parse_index(track_t trackp[], state_t *sp);
+static	void	parse_isrc(track_t trackp[], state_t *sp);
+static	void	parse_performer(track_t trackp[], state_t *sp);
+static	void	parse_postgap(track_t trackp[], state_t *sp);
+static	void	parse_pregap(track_t trackp[], state_t *sp);
+static	void	parse_songwriter(track_t trackp[], state_t *sp);
+static	void	parse_title(track_t trackp[], state_t *sp);
+static	void	parse_track(track_t trackp[], state_t *sp);
+static	void	parse_offset(long *lp);
+static	void	newtrack(track_t trackp[], state_t *sp);
 
-static	keyw_t	*lookup		__PR((char *word, keyw_t table[]));
-static	void	wdebug		__PR((void));
-static	FILE	*cueopen	__PR((char *name));
-static	char	*cuename	__PR((void));
-static	char	*nextline	__PR((FILE *f));
-static	void	ungetline	__PR((void));
-static	char	*skipwhite	__PR((const char *s));
-static	char	*peekword	__PR((void));
-static	char	*lineend	__PR((void));
-static	char	*markword	__PR((char *delim));
-static	char	getdelim	__PR((void));
-static	char	*getnextitem	__PR((char *delim));
-static	char	*neednextitem	__PR((char *delim));
-static	char	*nextword	__PR((void));
-static	char	*needword	__PR((void));
-static	char	*curword	__PR((void));
-static	char	*nextitem	__PR((void));
-static	char	*needitem	__PR((void));
-static	void	checkextra	__PR((void));
-static	void	cueabort	__PR((const char *fmt, ...));
+static	keyw_t	*lookup(char *word, keyw_t table[]);
+static	void	wdebug(void);
+static	FILE	*cueopen(char *name);
+static	char	*cuename(void);
+static	char	*nextline(FILE *f);
+static	void	ungetline(void);
+static	char	*skipwhite(const char *s);
+static	char	*peekword(void);
+static	char	*lineend(void);
+static	char	*markword(char *delim);
+static	char	getdelim(void);
+static	char	*getnextitem(char *delim);
+static	char	*neednextitem(char *delim);
+static	char	*nextword(void);
+static	char	*needword(void);
+static	char	*curword(void);
+static	char	*nextitem(void);
+static	char	*needitem(void);
+static	void	checkextra(void);
+static	void	cueabort(const char *fmt, ...);
 
 #ifdef	CUE_MAIN
 int	debug;
 int	xdebug = 1;
 
-int write_secs	__PR((void));
+int write_secs(void);
 int write_secs() { return (-1); }
 
-int
+int 
 main(int argc, char *argv[])
 {
 	int	i;
@@ -299,7 +296,7 @@
 extern	int	xdebug;
 #endif
 
-int
+int 
 parsecue(char *cuefname, track_t trackp[])
 {
 	FILE	*f = cueopen(cuefname);
@@ -308,7 +305,7 @@
 	return (0);
 }
 
-void
+void 
 fparsecue(FILE *f, track_t trackp[])
 {
 	char	*word;
@@ -397,7 +394,7 @@
 	} while (1);
 }
 
-static void
+static void 
 parse_mcn(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -414,7 +411,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_textfile(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -439,7 +436,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_file(track_t trackp[], state_t *sp)
 {
 	char	cname[1024];
@@ -538,7 +535,7 @@
 #endif
 }
 
-static void
+static void 
 parse_flags(track_t trackp[], state_t *sp)
 {
 	struct keyw *kp;
@@ -570,7 +567,7 @@
 		printf("Track %d flags 0x%08X\n", sp->track, sp->flags);
 }
 
-static void
+static void 
 parse_index(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -629,7 +626,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_isrc(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -652,7 +649,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_performer(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -665,7 +662,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_postgap(track_t trackp[], state_t *sp)
 {
 	long	l;
@@ -680,7 +677,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_pregap(track_t trackp[], state_t *sp)
 {
 	long	l;
@@ -696,7 +693,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_songwriter(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -709,7 +706,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_title(track_t trackp[], state_t *sp)
 {
 	char	*word;
@@ -722,7 +719,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_track(track_t trackp[], state_t *sp)
 {
 	struct keyw *kp;
@@ -836,7 +833,7 @@
 	checkextra();
 }
 
-static void
+static void 
 parse_offset(long *lp)
 {
 	char	*word;
@@ -873,7 +870,7 @@
 }
 
 /*--------------------------------------------------------------------------*/
-static void
+static void 
 newtrack(track_t trackp[], state_t *sp)
 {
 	register int	i;
@@ -1010,7 +1007,7 @@
 static	char	worddelim[] = "=:,/";
 static	char	nulldelim[] = "";
 
-static void
+static void 
 wdebug()
 {
 /*		printf("WORD: '%s' rest '%s'\n", word, peekword());*/
@@ -1064,7 +1061,7 @@
 	return (linep);
 }
 
-static void
+static void 
 ungetline()
 {
 	linelen = olinelen;
@@ -1134,7 +1131,7 @@
 	return (linep);
 }
 
-static char
+static char 
 getdelim()
 {
 	return (wordendc);
@@ -1193,7 +1190,7 @@
 	return (neednextitem(nulldelim));
 }
 
-static void
+static void 
 checkextra()
 {
 	if (peekword() < lineend())
@@ -1201,21 +1198,12 @@
 }
 
 /* VARARGS1 */
-#ifdef	PROTOTYPES
-static void
+static void 
 cueabort(const char *fmt, ...)
-#else
-static void
-cueabort(char *fmt, va_dcl va_alist)
-#endif
 {
 	va_list	args;
 
-#ifdef	PROTOTYPES
 	va_start(args, fmt);
-#else
-	va_start(args);
-#endif
 	comerrno(EX_BAD, "%r on line %d in '%s'.\n",
 		fmt, args, lineno, fname);
 	va_end(args);

Modified: nonameyet/branches/cleanup/cdrecord/defaults.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/defaults.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/defaults.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -31,9 +31,12 @@
 
 #define CFGPATH "/etc/default/wodim"
 /* The better way would be exporting the meta functions to getnum.h or so */
-extern int	getnum		(char *arg, long *valp);
+extern int	getnum(char *arg, long *valp);
 
-void cdr_defaults(char **p_dev_name, int *p_speed, long *p_fifosize, char **p_drv_opts) {
+void 
+cdr_defaults(char **p_dev_name, int *p_speed, long *p_fifosize, 
+					char **p_drv_opts)
+{
 	FILE *stream;
 	char *t; /* tmp */
 	int wc=0;

Modified: nonameyet/branches/cleanup/cdrecord/diskid.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/diskid.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/diskid.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -43,10 +43,10 @@
 
 #include "cdrecord.h"
 
-void	pr_manufacturer		__PR((msf_t *mp, BOOL rw, BOOL audio));
-static	struct disk_man * man_ptr	__PR((msf_t *mp));
-int	manufacturer_id		__PR((msf_t *mp));
-long	disk_rcap		__PR((msf_t *mp, long maxblock, BOOL rw, BOOL audio));
+void	pr_manufacturer(msf_t *mp, BOOL rw, BOOL audio);
+static	struct disk_man *man_ptr(msf_t *mp);
+int	manufacturer_id(msf_t *mp);
+long	disk_rcap(msf_t *mp, long maxblock, BOOL rw, BOOL audio);
 
 struct disk_man {
 	msf_t	mi_msf;
@@ -367,8 +367,7 @@
 	return (NULL);
 }
 
-void
-pr_manufacturer(msf_t *mp, BOOL rw, BOOL audio)
+void pr_manufacturer(msf_t *mp, BOOL rw, BOOL audio)
 {
 	struct disk_man * dp;
 	struct disk_man xdman;
@@ -422,8 +421,7 @@
 	}
 }
 
-int
-manufacturer_id(msf_t *mp)
+int manufacturer_id(msf_t *mp)
 {
 	struct disk_man * dp;
 
@@ -510,7 +508,7 @@
 	{{00, 00, 00}, 0L, 0L },
 };
 
-long
+long 
 disk_rcap(msf_t *mp, long maxblock, BOOL rw, BOOL audio)
 {
 	struct disk_rcap * dp;

Modified: nonameyet/branches/cleanup/cdrecord/drv_7501.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/drv_7501.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/drv_7501.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -225,28 +225,31 @@
 };
 
 
-static	int	cw7501_attach		__PR((SCSI *scgp, cdr_t *dp));
-static	int	cw7501_init		__PR((SCSI *scgp, cdr_t *dp));
-static	int	cw7501_getdisktype	__PR((SCSI *scgp, cdr_t *dp));
-static	int	cw7501_speed_select	__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	cw7501_next_wr_addr	__PR((SCSI *scgp, track_t *trackp, long *ap));
-static	int	cw7501_write		__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-static	int	cw7501_write_leadin	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	cw7501_open_track	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	cw7501_close_track	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	cw7501_open_session	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	cw7501_gen_cue		__PR((track_t *trackp, void *vcuep, BOOL needgap));
-static	void	fillcue			__PR((struct cw7501_cue *cp, int ca, int tno, int idx, int dataform, int scms, msf_t *mp));
-static	int	cw7501_send_cue		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	cw7501_fixate		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	cw7501_rezero		__PR((SCSI *scgp, int reset, int dwreset));
-static	int	cw7501_read_trackinfo	__PR((SCSI *scgp, Uchar *bp, int count, int track, int mode));
-static	int	cw7501_write_dao	__PR((SCSI *scgp, Uchar *bp, int len, int disktype));
-static	int	cw7501_reserve_track	__PR((SCSI *scgp, unsigned long));
-static	int	cw7501_set_mode		__PR((SCSI *scgp, int phys_form, int control,
+static	int	cw7501_attach(SCSI *scgp, cdr_t *dp);
+static	int	cw7501_init(SCSI *scgp, cdr_t *dp);
+static	int	cw7501_getdisktype(SCSI *scgp, cdr_t *dp);
+static	int	cw7501_speed_select(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	cw7501_next_wr_addr(SCSI *scgp, track_t *trackp, long *ap);
+static	int	cw7501_write(SCSI *scgp, caddr_t bp, long sectaddr, long size, 
+									 int blocks, BOOL islast);
+static	int	cw7501_write_leadin(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	cw7501_open_track(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	cw7501_close_track(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	cw7501_open_session(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	cw7501_gen_cue(track_t *trackp, void *vcuep, BOOL needgap);
+static	void	fillcue(struct cw7501_cue *cp, int ca, int tno, int idx, 
+							  int dataform, int scms, msf_t *mp);
+static	int	cw7501_send_cue(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	cw7501_fixate(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	cw7501_rezero(SCSI *scgp, int reset, int dwreset);
+static	int	cw7501_read_trackinfo(SCSI *scgp, Uchar *bp, int count, 
+												 int track, int mode);
+static	int	cw7501_write_dao(SCSI *scgp, Uchar *bp, int len, int disktype);
+static	int	cw7501_reserve_track(SCSI *scgp, unsigned long);
+static	int	cw7501_set_mode(SCSI *scgp, int phys_form, int control,
 						int subc, int alt, int trackno, int tindex,
-						int packet_size, int write_mode));
-static	int	cw7501_finalize		__PR((SCSI *scgp, int pad, int fixed));
+						int packet_size, int write_mode);
+static	int	cw7501_finalize(SCSI *scgp, int pad, int fixed);
 
 
 cdr_t	cdr_cw7501 = {
@@ -269,7 +272,7 @@
 	scsi_unload,
 	buf_dummy,				/* RD buffer cap not supp. */
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	cw7501_speed_select,
 	select_secsize,
 	cw7501_next_wr_addr,
@@ -288,7 +291,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -328,20 +331,20 @@
 	NULL
 };
 
-static int
+static int 
 cw7501_attach(SCSI *scgp, cdr_t *dp)
 {
 	scg_setnonstderrs(scgp, sd_cw7501_error_str);
 	return (0);
 }
 
-static int
+static int 
 cw7501_init(SCSI *scgp, cdr_t *dp)
 {
 	return (cw7501_speed_select(scgp, dp, NULL));
 }
 
-static int
+static int 
 cw7501_getdisktype(SCSI *scgp, cdr_t *dp)
 {
 	Ulong	maxb = 0;
@@ -404,7 +407,7 @@
 }
 
 
-static int
+static int 
 cw7501_speed_select(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	struct	scsi_mode_page_header	*mp;
@@ -461,7 +464,7 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
+static int 
 cw7501_next_wr_addr(SCSI *scgp, track_t *trackp, long *ap)
 {
 	struct cw7501_nwa	*nwa;
@@ -506,7 +509,7 @@
 	return (0);
 }
 
-static int
+static int 
 cw7501_write(SCSI *scgp, 
              caddr_t bp     /* address of buffer */, 
              long sectaddr  /* disk address (sector) to put */, 
@@ -520,7 +523,7 @@
 	return (write_xg0(scgp, bp, 0, size, blocks));
 }
 
-static int
+static int 
 cw7501_write_leadin(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uint	i;
@@ -572,7 +575,7 @@
 	0xFF,			/* 15 -    Vendor specific			*/
 };
 
-static int
+static int 
 cw7501_open_track(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	struct	scsi_mode_page_header	*mp;
@@ -632,7 +635,7 @@
 }
 
 
-static int
+static int 
 cw7501_close_track(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	if (!is_tao(trackp) && !is_packet(trackp)) {
@@ -641,7 +644,7 @@
 	return (scsi_flush_cache(scgp, FALSE));
 }
 
-static int
+static int 
 cw7501_open_session(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	struct cw7501_mode_data		md;
@@ -695,7 +698,7 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
+static int 
 cw7501_fixate(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	if (!is_tao(trackp) && !is_packet(trackp)) {
@@ -711,7 +714,7 @@
 
 /*--------------------------------------------------------------------------*/
 
-static int
+static int 
 cw7501_gen_cue(track_t *trackp, void *vcuep, BOOL needgap)
 {
 	int	tracks = trackp->tracks;
@@ -814,14 +817,14 @@
 	return (ncue);
 }
 
-static void
-fillcue(struct cw7501_cue *cp   /* The target cue entry */, 
-        int ca                  /* Control/adr for this entry */, 
-        int tno                 /* Track number for this entry */, 
-        int idx                 /* Index for this entry */, 
-        int dataform            /* Data format for this entry */, 
-        int scms                /* Serial copy management */, 
-        msf_t *mp               /* MSF value for this entry */)
+static void 
+fillcue(struct cw7501_cue *cp	/* The target cue entry */, 
+        int ca					/* Control/adr for this entry */, 
+        int tno					/* Track number for this entry */, 
+        int idx					/* Index for this entry */, 
+        int dataform			/* Data format for this entry */, 
+        int scms					/* Serial copy management */, 
+        msf_t *mp				/* MSF value for this entry */)
 {
 	cp->cs_ctladr = ca;
 	if (tno <= 99)
@@ -838,7 +841,7 @@
 	cp->cs_frame = to_bcd(mp->msf_frame);
 }
 
-static int
+static int 
 cw7501_send_cue(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	struct cw7501_cue *cp;
@@ -882,7 +885,7 @@
 }
 
 /*--------------------------------------------------------------------------*/
-static int
+static int 
 cw7501_rezero(SCSI *scgp, int reset, int dwreset)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -929,7 +932,7 @@
 	return (0);
 }
 
-static int
+static int 
 cw7501_write_dao(SCSI *scgp, Uchar *bp, int len, int disktype)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -956,7 +959,7 @@
  * XXX CW-7501 also needs "control", so we need to make a different
  * XXX driver interface.
  */
-static int
+static int 
 cw7501_reserve_track(SCSI *scgp, unsigned long len)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -979,9 +982,10 @@
 	return (0);
 }
 
-static int
-cw7501_set_mode(SCSI *scgp, int phys_form, int control, int subc, int alt, 
-                int trackno, int tindex, int packet_size, int write_mode)
+static int 
+cw7501_set_mode(SCSI *scgp, int phys_form, int control, int subc, 
+						int alt, int trackno, int tindex, int packet_size, 
+						int write_mode)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1007,7 +1011,7 @@
 	return (0);
 }
 
-static int
+static int 
 cw7501_finalize(SCSI *scgp, int pad, int fixed)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;

Modified: nonameyet/branches/cleanup/cdrecord/drv_jvc.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/drv_jvc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/drv_jvc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -220,39 +220,41 @@
 #endif
 
 
-static	int	teac_attach		__PR((SCSI *scgp, cdr_t *dp));
-static	int	teac_init		__PR((SCSI *scgp, cdr_t *dp));
-static	int	teac_getdisktype	__PR((SCSI *scgp, cdr_t *dp));
-static	int	speed_select_teac	__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	select_secsize_teac	__PR((SCSI *scgp, track_t *trackp));
-static	int	next_wr_addr_jvc	__PR((SCSI *scgp, track_t *, long *ap));
-static	int	write_teac_xg1		__PR((SCSI *scgp, caddr_t, long, long, int, BOOL));
-static	int	cdr_write_teac		__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-static	int	open_track_jvc		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	teac_fixation		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	close_track_teac	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	teac_open_session	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	initsub_teac		__PR((SCSI *scgp, int toctype, int multi));
-static	int	teac_doopc		__PR((SCSI *scgp));
-static	int	teac_opc		__PR((SCSI *scgp, caddr_t, int cnt, int doopc));
-static	int	opt_power_judge		__PR((SCSI *scgp, int judge));
-static	int	clear_subcode		__PR((SCSI *scgp));
-static	int	set_limits		__PR((SCSI *scgp, long lba, long length));
-static	int	set_subcode		__PR((SCSI *scgp, Uchar *subcode_data, int length));
-static	int	read_disk_info_teac	__PR((SCSI *scgp, Uchar *data, int length, int type));
-static	int	teac_freeze		__PR((SCSI *scgp, int bp_flag));
-static	int	teac_wr_pma		__PR((SCSI *scgp));
-static	int	teac_rd_pma		__PR((SCSI *scgp));
-static	int	next_wr_addr_teac	__PR((SCSI *scgp, long start_lba, long last_lba));
-static	int	blank_jvc		__PR((SCSI *scgp, cdr_t *dp, long addr, int blanktype));
-static	int	buf_cap_teac		__PR((SCSI *scgp, long *sp, long *fp));
-static	long	read_peak_buffer_cap_teac __PR((SCSI *scgp));
-static	int	buffer_inquiry_teac	__PR((SCSI *scgp, int fmt));
+static	int	teac_attach(SCSI *scgp, cdr_t *dp);
+static	int	teac_init(SCSI *scgp, cdr_t *dp);
+static	int	teac_getdisktype(SCSI *scgp, cdr_t *dp);
+static	int	speed_select_teac(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	select_secsize_teac(SCSI *scgp, track_t *trackp);
+static	int	next_wr_addr_jvc(SCSI *scgp, track_t *, long *ap);
+static	int	write_teac_xg1(SCSI *scgp, caddr_t, long, long, int, BOOL);
+static	int	cdr_write_teac(SCSI *scgp, caddr_t bp, long sectaddr, long size, 
+										int blocks, BOOL islast);
+static	int	open_track_jvc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	teac_fixation(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	close_track_teac(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	teac_open_session(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	initsub_teac(SCSI *scgp, int toctype, int multi);
+static	int	teac_doopc(SCSI *scgp);
+static	int	teac_opc(SCSI *scgp, caddr_t, int cnt, int doopc);
+static	int	opt_power_judge(SCSI *scgp, int judge);
+static	int	clear_subcode(SCSI *scgp);
+static	int	set_limits(SCSI *scgp, long lba, long length);
+static	int	set_subcode(SCSI *scgp, Uchar *subcode_data, int length);
+static	int	read_disk_info_teac(SCSI *scgp, Uchar *data, int length, 
+											  int type);
+static	int	teac_freeze(SCSI *scgp, int bp_flag);
+static	int	teac_wr_pma(SCSI *scgp);
+static	int	teac_rd_pma(SCSI *scgp);
+static	int	next_wr_addr_teac(SCSI *scgp, long start_lba, long last_lba);
+static	int	blank_jvc(SCSI *scgp, cdr_t *dp, long addr, int blanktype);
+static	int	buf_cap_teac(SCSI *scgp, long *sp, long *fp);
+static	long	read_peak_buffer_cap_teac(SCSI *scgp);
+static	int	buffer_inquiry_teac(SCSI *scgp, int fmt);
 #ifdef	XXBUFFER
-static	void	check_buffer_teac	__PR((SCSI *scgp));
+static	void	check_buffer_teac(SCSI *scgp);
 #endif
 #ifdef	XXDEBUG
-static	void	xxtest_teac		__PR((SCSI *scgp));
+static	void	xxtest_teac(SCSI *scgp);
 #endif
 
 
@@ -274,15 +276,15 @@
 	scsi_unload,
 	buf_cap_teac,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_teac,
 	select_secsize,
 	next_wr_addr_jvc,
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	cdr_write_teac,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_jvc,
 	close_track_teac,
 	teac_open_session,
@@ -299,13 +301,13 @@
 	cmd_dummy,					/* opt2		*/
 };
 
-static int
+static int 
 teac_init(SCSI *scgp, cdr_t *dp)
 {
 	return (speed_select_teac(scgp, dp, NULL));
 }
 
-static int
+static int 
 teac_getdisktype(SCSI *scgp, cdr_t *dp)
 {
 	dstat_t	*dsp = dp->cdr_dstat;
@@ -332,7 +334,7 @@
 	return (drive_getdisktype(scgp, dp));
 }
 
-static int
+static int 
 speed_select_teac(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	struct cdd_52x_mode_data md;
@@ -373,7 +375,7 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
+static int 
 select_secsize_teac(SCSI *scgp, track_t *trackp)
 {
 	struct scsi_mode_data md;
@@ -404,7 +406,7 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
+static int 
 next_wr_addr_jvc(SCSI *scgp, track_t *trackp, long *ap)
 {
 	if (trackp != 0 && trackp->track > 0) {
@@ -420,7 +422,7 @@
 	return (0);
 }
 
-static int
+static int 
 write_teac_xg1(SCSI *scgp, 
                caddr_t bp       /* address of buffer */, 
                long sectaddr    /* disk address (sector) to put */, 
@@ -450,12 +452,12 @@
 	return (size - scg_getresid(scgp));
 }
 
-static int
+static int 
 cdr_write_teac(SCSI *scgp, 
-               caddr_t bp       /* address of buffer */, 
-               long sectaddr    /* disk address (sector) to put */, 
-               long size        /* number of bytes to transfer */, 
-               int blocks       /* sector count */, 
+               caddr_t bp       /* address of buffer */,
+               long sectaddr    /* disk address (sector) to put */,
+               long size        /* number of bytes to transfer */,
+               int blocks       /* sector count */,
                BOOL islast      /* last write for track */)
 {
 	int	ret;
@@ -474,7 +476,7 @@
 	return (ret);
 }
 
-static int
+static int 
 open_track_jvc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	int	status;
@@ -602,7 +604,7 @@
 
 static	char	sector[3000];
 
-static int
+static int 
 close_track_teac(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	int	ret = 0;
@@ -688,7 +690,7 @@
 	NULL
 };
 
-static int
+static int 
 teac_attach(SCSI *scgp, cdr_t *dp)
 {
 	scg_setnonstderrs(scgp, sd_teac50_error_str);
@@ -699,7 +701,7 @@
 	return (0);
 }
 
-static int
+static int 
 teac_fixation(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	long	lba;
@@ -812,7 +814,7 @@
 
 }
 
-static int
+static int 
 teac_open_session(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uint	i;
@@ -832,7 +834,7 @@
 				track_base(trackp)->tracktype & TOCF_MULTI));
 }
 
-static int
+static int 
 initsub_teac(SCSI *scgp, int toctype, int multi)
 {
 	int	status;
@@ -849,7 +851,7 @@
 	return (0);
 }
 
-static int
+static int 
 teac_doopc(SCSI *scgp)
 {
 	int	status;
@@ -884,7 +886,7 @@
 	return (status);
 }
 
-static int
+static int 
 teac_opc(SCSI *scgp, caddr_t bp, int cnt, int doopc)
 {
 	int	status;
@@ -915,7 +917,7 @@
 /*
  * Optimum power calibration for Teac Drives.
  */
-static int
+static int 
 opt_power_judge(SCSI *scgp, int judge)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -940,7 +942,7 @@
 /*
  * Clear subcodes for Teac Drives.
  */
-static int
+static int 
 clear_subcode(SCSI *scgp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -964,7 +966,7 @@
 /*
  * Set limits for command linking for Teac Drives.
  */
-static int
+static int 
 set_limits(SCSI *scgp, long lba, long length)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -989,7 +991,7 @@
 /*
  * Set subcode for Teac Drives.
  */
-static int
+static int 
 set_subcode(SCSI *scgp, Uchar *subcode_data, int length)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -1010,7 +1012,7 @@
 	return (scg_cmd(scgp));
 }
 
-static int
+static int 
 read_disk_info_teac(SCSI *scgp, Uchar *data, int length, int type)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -1036,7 +1038,7 @@
 /*
  * Perform the freeze command for Teac Drives.
  */
-static int
+static int 
 teac_freeze(SCSI *scgp, int bp_flag)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -1058,7 +1060,7 @@
 	return (scg_cmd(scgp));
 }
 
-static int
+static int 
 teac_wr_pma(SCSI *scgp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -1081,7 +1083,7 @@
 /*
  * Read PMA for Teac Drives.
  */
-static int
+static int 
 teac_rd_pma(SCSI *scgp)
 {
 	unsigned char	xx[256];
@@ -1127,7 +1129,7 @@
 /*
  * Next writable address for Teac Drives.
  */
-static int
+static int 
 next_wr_addr_teac(SCSI *scgp, long start_lba, long last_lba)
 {
 	unsigned char	xx[256];
@@ -1164,7 +1166,7 @@
 	return (0);
 }
 
-static int
+static int 
 blank_jvc(SCSI *scgp, cdr_t *dp, long addr, int blanktype)
 {
 	extern	char	*blank_types[];
@@ -1177,7 +1179,7 @@
 	return (scsi_blank(scgp, addr, blanktype, FALSE));
 }
 
-static int
+static int 
 buf_cap_teac(SCSI *scgp, long *sp, long *fp)
 {
 	Ulong	freespace;
@@ -1208,7 +1210,7 @@
 	return (per);
 }
 
-static long
+static long 
 read_peak_buffer_cap_teac(SCSI *scgp)
 {
 	Uchar	xx[4];
@@ -1247,7 +1249,7 @@
 #define	BI_448_BYTE	0x40
 #define	BI_APP_CODE	0x10
 
-static int
+static int 
 buffer_inquiry_teac(SCSI *scgp, int fmt)
 {
 	Uchar	xx[448];
@@ -1297,7 +1299,7 @@
 }
 
 #ifdef	XXBUFFER
-static void
+static void 
 check_buffer_teac(SCSI *scgp)
 {
 	printf("-------\n");
@@ -1313,10 +1315,10 @@
 #ifdef	XXDEBUG
 #include "scsimmc.h"
 
-static	int	g7_teac			__PR((SCSI *scgp));
-static	int	g6_teac			__PR((SCSI *scgp));
+static	int	g7_teac(SCSI *scgp);
+static	int	g6_teac(SCSI *scgp);
 
-static int
+static int 
 g7_teac(SCSI *scgp)
 {
 	Uchar	xx[2048];
@@ -1356,7 +1358,7 @@
 	return (0);
 }
 
-static int
+static int 
 g6_teac(SCSI *scgp)
 {
 	Uchar	xx[2048];
@@ -1395,7 +1397,7 @@
 	return (0);
 }
 
-static void
+static void 
 xxtest_teac(SCSI *scgp)
 {
 	read_peak_buffer_cap_teac(scgp);

Modified: nonameyet/branches/cleanup/cdrecord/drv_mmc.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/drv_mmc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/drv_mmc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -88,90 +88,96 @@
 };
 
 #ifdef	__needed__
-static	int	mmc_load		__PR((SCSI *scgp, cdr_t *dp));
-static	int	mmc_unload		__PR((SCSI *scgp, cdr_t *dp));
+static	int	mmc_load(SCSI *scgp, cdr_t *dp);
+static	int	mmc_unload(SCSI *scgp, cdr_t *dp);
 #endif
-void	mmc_opthelp		__PR((cdr_t *dp, int excode));
-char	*hasdrvopt		__PR((char *optstr, char *optname));
-static	cdr_t	*identify_mmc		__PR((SCSI *scgp, cdr_t *, struct scsi_inquiry *));
-static	int	attach_mmc		__PR((SCSI *scgp, cdr_t *));
-static   int     attach_mdvd             __PR((SCSI *scgp, cdr_t *));
-int	check_writemodes_mmc	__PR((SCSI *scgp, cdr_t *dp));
- int     check_writemodes_mdvd   __PR((SCSI *scgp, cdr_t *dp));
-static	int	deflt_writemodes_mmc	__PR((SCSI *scgp, BOOL reset_dummy));
-static   int     deflt_writemodes_mdvd   __PR((SCSI *scgp, BOOL reset_dummy));
-static	int	get_diskinfo		__PR((SCSI *scgp, struct disk_info *dip));
-static	void	di_to_dstat		__PR((struct disk_info *dip, dstat_t *dsp));
-static	int	get_atip		__PR((SCSI *scgp, struct atipinfo *atp));
+void				mmc_opthelp(cdr_t *dp, int excode);
+char				*hasdrvopt(char *optstr, char *optname);
+static	cdr_t	*identify_mmc(SCSI *scgp, cdr_t *, struct scsi_inquiry *);
+static	int	attach_mmc(SCSI *scgp, cdr_t *);
+static   int   attach_mdvd(SCSI *scgp, cdr_t *);
+int				check_writemodes_mmc(SCSI *scgp, cdr_t *dp);
+int     			check_writemodes_mdvd(SCSI *scgp, cdr_t *dp);
+static	int	deflt_writemodes_mmc(SCSI *scgp, BOOL reset_dummy);
+static   int   deflt_writemodes_mdvd(SCSI *scgp, BOOL reset_dummy);
+static	int	get_diskinfo(SCSI *scgp, struct disk_info *dip);
+static	void	di_to_dstat(struct disk_info *dip, dstat_t *dsp);
+static	int	get_atip(SCSI *scgp, struct atipinfo *atp);
 #ifdef	PRINT_ATIP
-static	int	get_pma			__PR((SCSI *scgp));
+static	int	get_pma(SCSI *scgp);
 #endif
-static	int	init_mmc		__PR((SCSI *scgp, cdr_t *dp));
-static	int	getdisktype_mmc		__PR((SCSI *scgp, cdr_t *dp));
-static   int     getdisktype_mdvd        __PR((SCSI *scgp, cdr_t *dp));
-static	int	speed_select_mmc	__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static   int     speed_select_mdvd       __PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	mmc_set_speed		__PR((SCSI *scgp, int readspeed, int writespeed, int rotctl));
-static	int	next_wr_addr_mmc	__PR((SCSI *scgp, track_t *trackp, long *ap));
-static   int     next_wr_addr_mdvd       __PR((SCSI *scgp, track_t *trackp, long *ap));
-static	int	write_leadin_mmc	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	open_track_mmc		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static   int     open_track_mdvd         __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	close_track_mmc		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static   int     close_track_mdvd        __PR((SCSI *scgp, cdr_t *dp, track_t *trackp)); 
-static	int	open_session_mmc	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static   int     open_session_mdvd       __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	waitfix_mmc		__PR((SCSI *scgp, int secs));
-static	int	fixate_mmc		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static   int     fixate_mdvd             __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	blank_mmc		__PR((SCSI *scgp, cdr_t *dp, long addr, int blanktype));
-static	int	format_mdvd		__PR((SCSI *scgp, cdr_t *dp, int formattype));
-static	int	send_opc_mmc		__PR((SCSI *scgp, caddr_t, int cnt, int doopc));
-static	int	opt1_mmc		__PR((SCSI *scgp, cdr_t *dp));
-static	int	opt1_mdvd		__PR((SCSI *scgp, cdr_t *dp));
-static	int	opt2_mmc		__PR((SCSI *scgp, cdr_t *dp));
-static	int	scsi_sony_write		__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-static	int	gen_cue_mmc		__PR((track_t *trackp, void *vcuep, BOOL needgap));
-static	void	fillcue			__PR((struct mmc_cue *cp, int ca, int tno, int idx, int dataform, int scms, msf_t *mp));
-static	int	send_cue_mmc		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static int	stats_mmc		__PR((SCSI *scgp, cdr_t *dp));
-static BOOL	mmc_isplextor		__PR((SCSI *scgp));
-static BOOL	mmc_isyamaha		__PR((SCSI *scgp));
-static void	do_varirec_plextor	__PR((SCSI *scgp));
-static int	do_gigarec_plextor	__PR((SCSI *scgp));
-static int	drivemode_plextor	__PR((SCSI *scgp, caddr_t bp, int cnt, int modecode, void *modeval));
-static int	drivemode2_plextor	__PR((SCSI *scgp, caddr_t bp, int cnt, int modecode, void *modeval));
-static int	check_varirec_plextor	__PR((SCSI *scgp));
-static int	check_gigarec_plextor	__PR((SCSI *scgp));
-static int	varirec_plextor		__PR((SCSI *scgp, BOOL on, int val));
-static int	gigarec_plextor		__PR((SCSI *scgp, int val));
-static Int32_t	gigarec_mult		__PR((int code, Int32_t	val));
-static int	check_ss_hide_plextor	__PR((SCSI *scgp));
-static int	check_speed_rd_plextor	__PR((SCSI *scgp));
-static int	check_powerrec_plextor	__PR((SCSI *scgp));
-static int	ss_hide_plextor		__PR((SCSI *scgp, BOOL do_ss, BOOL do_hide));
-static int	speed_rd_plextor	__PR((SCSI *scgp, BOOL do_speedrd));
-static int	powerrec_plextor	__PR((SCSI *scgp, BOOL do_powerrec));
-static int	get_speeds_plextor	__PR((SCSI *scgp, int *selp, int *maxp, int *lastp));
-static int	bpc_plextor		__PR((SCSI *scgp, int mode, int *bpp));
-static int	set_audiomaster_yamaha	__PR((SCSI *scgp, cdr_t *dp, BOOL keep_mode));
+static	int	init_mmc(SCSI *scgp, cdr_t *dp);
+static	int	getdisktype_mmc(SCSI *scgp, cdr_t *dp);
+static  int   getdisktype_mdvd(SCSI *scgp, cdr_t *dp);
+static	int	speed_select_mmc(SCSI *scgp, cdr_t *dp, int *speedp);
+static  int   speed_select_mdvd(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	mmc_set_speed(SCSI *scgp, int readspeed, int writespeed, 
+									  int rotctl);
+static	int	next_wr_addr_mmc(SCSI *scgp, track_t *trackp, long *ap);
+static  int   next_wr_addr_mdvd(SCSI *scgp, track_t *trackp, long *ap);
+static	int	write_leadin_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	open_track_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static  int   open_track_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	close_track_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static  int   close_track_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp); 
+static	int	open_session_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static  int   open_session_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	waitfix_mmc(SCSI *scgp, int secs);
+static	int	fixate_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static  int   fixate_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	blank_mmc(SCSI *scgp, cdr_t *dp, long addr, int blanktype);
+static	int	format_mdvd(SCSI *scgp, cdr_t *dp, int formattype);
+static	int	send_opc_mmc(SCSI *scgp, caddr_t, int cnt, int doopc);
+static	int	opt1_mmc(SCSI *scgp, cdr_t *dp);
+static	int	opt1_mdvd(SCSI *scgp, cdr_t *dp);
+static	int	opt2_mmc(SCSI *scgp, cdr_t *dp);
+static	int	scsi_sony_write(SCSI *scgp, caddr_t bp, long sectaddr, long size, 
+										 int blocks, BOOL islast);
+static	int	gen_cue_mmc(track_t *trackp, void *vcuep, BOOL needgap);
+static	void	fillcue(struct mmc_cue *cp, int ca, int tno, int idx, int dataform,
+							 int scms, msf_t *mp);
+static	int	send_cue_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static 	int	stats_mmc(SCSI *scgp, cdr_t *dp);
+static 	BOOL	mmc_isplextor(SCSI *scgp);
+static 	BOOL	mmc_isyamaha(SCSI *scgp);
+static 	void	do_varirec_plextor(SCSI *scgp);
+static 	int	do_gigarec_plextor(SCSI *scgp);
+static 	int	drivemode_plextor(SCSI *scgp, caddr_t bp, int cnt, int modecode, 
+											void *modeval);
+static 	int	drivemode2_plextor(SCSI *scgp, caddr_t bp, int cnt, int modecode, 
+											 void *modeval);
+static 	int	check_varirec_plextor(SCSI *scgp);
+static 	int	check_gigarec_plextor(SCSI *scgp);
+static 	int	varirec_plextor(SCSI *scgp, BOOL on, int val);
+static 	int	gigarec_plextor(SCSI *scgp, int val);
+static 	Int32_t	gigarec_mult(int code, Int32_t	val);
+static 	int	check_ss_hide_plextor(SCSI *scgp);
+static 	int	check_speed_rd_plextor(SCSI *scgp);
+static 	int	check_powerrec_plextor(SCSI *scgp);
+static 	int	ss_hide_plextor(SCSI *scgp, BOOL do_ss, BOOL do_hide);
+static 	int	speed_rd_plextor(SCSI *scgp, BOOL do_speedrd);
+static 	int	powerrec_plextor(SCSI *scgp, BOOL do_powerrec);
+static 	int	get_speeds_plextor(SCSI *scgp, int *selp, int *maxp, int *lastp);
+static 	int	bpc_plextor(SCSI *scgp, int mode, int *bpp);
+static 	int	set_audiomaster_yamaha(SCSI *scgp, cdr_t *dp, BOOL keep_mode);
 
-struct ricoh_mode_page_30 * get_justlink_ricoh	__PR((SCSI *scgp, Uchar *mode));
-static int	force_speed_yamaha	__PR((SCSI *scgp, int readspeed, int writespeed));
-static BOOL	get_tattoo_yamaha	__PR((SCSI *scgp, BOOL print, Int32_t *irp, Int32_t *orp));
-static int	do_tattoo_yamaha	__PR((SCSI *scgp, FILE *f));
-static int	yamaha_write_buffer	__PR((SCSI *scgp, int mode, int bufferid, long offset,
-							long parlen, void *buffer, long buflen));
-static	int	dvd_dual_layer_split	__PR((SCSI *scgp, cdr_t *dp, long tsize));
+struct 	ricoh_mode_page_30 * get_justlink_ricoh(SCSI *scgp, Uchar *mode);
+static 	int	force_speed_yamaha(SCSI *scgp, int readspeed, int writespeed);
+static 	BOOL	get_tattoo_yamaha(SCSI *scgp, BOOL print, Int32_t *irp, 
+										Int32_t *orp);
+static 	int	do_tattoo_yamaha(SCSI *scgp, FILE *f);
+static 	int	yamaha_write_buffer(SCSI *scgp, int mode, int bufferid, long offset,
+										  long parlen, void *buffer, long buflen);
+static	int	dvd_dual_layer_split(SCSI *scgp, cdr_t *dp, long tsize);
 
 #ifdef	__needed__
-static int
+static int 
 mmc_load(SCSI *scgp, cdr_t *dp)
 {
 	return (scsi_load_unload(scgp, 1));
 }
 
-static int
+static int 
 mmc_unload(SCSI *scgp, cdr_t *dp)
 {
 	return (scsi_load_unload(scgp, 0));
@@ -198,11 +204,11 @@
 	scsi_unload,
 	read_buff_cap,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_mmc,
 	select_secsize,
 	next_wr_addr_mmc,
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	scsi_cdr_write,
 	gen_cue_mmc,
 	send_cue_mmc,
@@ -239,14 +245,14 @@
          scsi_unload,
          read_buff_cap,
          cmd_dummy,                              /* recovery_needed      */
-         (int(*)__PR((SCSI *, int)))cmd_dummy,   /* recover              */
+         (int(*)(SCSI *, int))cmd_dummy,   /* recover              */
          speed_select_mdvd,
          select_secsize,
          next_wr_addr_mdvd,
-         (int(*)__PR((SCSI *, Ulong)))cmd_ill,   /* reserve_track        */
+         (int(*)(SCSI *, Ulong))cmd_ill,   /* reserve_track        */
          scsi_cdr_write,
-         (int(*)__PR((SCSI *scgp, int, track_t *)))cmd_dummy, /* gen_cue */
-	 (int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy, /* send_cue */
+         (int(*)(SCSI *scgp, int, track_t *))cmd_dummy, /* gen_cue */
+	 (int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy, /* send_cue */
  	 write_leadin_mmc,
          open_track_mdvd,
          close_track_mdvd,
@@ -284,11 +290,11 @@
 	scsi_unload,
 	read_buff_cap,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_mmc,
 	select_secsize,
 	next_wr_addr_mmc,
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	scsi_sony_write,
 	gen_cue_mmc,
 	send_cue_mmc,
@@ -328,26 +334,26 @@
 	scsi_unload,
 	read_buff_cap,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_mmc,
 	select_secsize,
-	(int(*)__PR((SCSI *scgp, track_t *, long *)))cmd_ill,	/* next_wr_addr		*/
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *scgp, track_t *, long *))cmd_ill,	/* next_wr_addr		*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	scsi_cdr_write,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_mmc,
 	close_track_mmc,
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset,
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy,	/* fixation */
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy,	/* fixation */
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -372,26 +378,26 @@
 	scsi_unload,
 	buf_dummy,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_mmc,
 	select_secsize,
-	(int(*)__PR((SCSI *scg, track_t *, long *)))cmd_ill,	/* next_wr_addr		*/
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *scg, track_t *, long *))cmd_ill,	/* next_wr_addr		*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	scsi_cdr_write,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_mmc,
 	close_track_mmc,
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy,	/* fixation */
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy,	/* fixation */
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -417,31 +423,31 @@
 	scsi_unload,
 	read_buff_cap,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_mmc,
 	select_secsize,
-	(int(*)__PR((SCSI *scgp, track_t *, long *)))cmd_ill,	/* next_wr_addr		*/
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *scgp, track_t *, long *))cmd_ill,	/* next_wr_addr		*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	scsi_cdr_write,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_mmc,
 	close_track_mmc,
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset,
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy,	/* fixation */
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy,	/* fixation */
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
 
-void
+void 
 mmc_opthelp(cdr_t *dp, int excode)
 {
 	BOOL	haveopts = FALSE;
@@ -738,7 +744,7 @@
 	return (dp);
 }
 
-static int
+static int 
 attach_mmc(SCSI *scgp, cdr_t *dp)
 {
 	int	ret;
@@ -938,7 +944,7 @@
 	return (0);
 }
 
-static int
+static int 
 attach_mdvd(SCSI *scgp, cdr_t *dp)
 {
         struct  cd_mode_page_2A *mp;
@@ -973,7 +979,7 @@
         return (0);
 }
 
-int
+int 
 check_writemodes_mmc(SCSI *scgp, cdr_t *dp)
 {
 	Uchar	mode[0x100];
@@ -1118,7 +1124,7 @@
 	return (0);
 }
 
-int
+int 
 check_writemodes_mdvd(SCSI *scgp, cdr_t *dp)
 {
 	Uchar	mode[0x100];
@@ -1187,7 +1193,7 @@
 	return (0);
 }
 
-static int
+static int 
 deflt_writemodes_mmc(SCSI *scgp, BOOL reset_dummy)
 {
 	Uchar	mode[0x100];
@@ -1259,7 +1265,7 @@
 	return (0);
 }
 
-static int
+static int 
 deflt_writemodes_mdvd(SCSI *scgp, BOOL reset_dummy)
 {
 	Uchar	mode[0x100];
@@ -1313,12 +1319,12 @@
 }
 
 #ifdef	PRINT_ATIP
-static	void	print_di		__PR((struct disk_info *dip));
-static	void	atip_printspeed		__PR((char *fmt, int speedindex, char speedtab[]));
-static	void	print_atip		__PR((SCSI *scgp, struct atipinfo *atp));
+static	void	print_di(struct disk_info *dip);
+static	void	atip_printspeed(char *fmt, int speedindex, char speedtab[]);
+static	void	print_atip(SCSI *scgp, struct atipinfo *atp);
 #endif	/* PRINT_ATIP */
 
-static int
+static int 
 get_diskinfo(SCSI *scgp, struct disk_info *dip)
 {
 	int	len;
@@ -1344,7 +1350,7 @@
 	return (ret);
 }
 
-static void
+static void 
 di_to_dstat(struct disk_info *dip, dstat_t *dsp)
 {
 	dsp->ds_diskid = a_to_u_4_byte(dip->disk_id);
@@ -1382,7 +1388,7 @@
 	dsp->ds_trfirst_ls=dip->first_track_ls;
 }
 
-static int
+static int 
 get_atip(SCSI *scgp, struct atipinfo *atp)
 {
 	int	len;
@@ -1436,14 +1442,12 @@
 
 #ifdef	PRINT_ATIP
 
-static int
-/*get_pma(atp)*/
+static int 
 get_pma(SCSI *scgp)
-/*	struct atipinfo *atp;*/
 {
 	int	len;
 	int	ret;
-char	atp[1024];
+	char	atp[1024];
 
 	fillbytes((caddr_t)atp, sizeof (*atp), '\0');
 
@@ -1478,13 +1482,13 @@
 
 #endif	/* PRINT_ATIP */
 
-static int
+static int 
 init_mmc(SCSI *scgp, cdr_t *dp)
 {
 	return (speed_select_mmc(scgp, dp, NULL));
 }
 
-static int
+static int 
 getdisktype_mdvd(SCSI *scgp, cdr_t *dp)
 {
        int ret = 0;
@@ -1506,7 +1510,7 @@
   
 }
 
-static int
+static int 
 getdisktype_mmc(SCSI *scgp, cdr_t *dp)
 {
 extern	char	*buf;
@@ -1664,11 +1668,11 @@
 #define	VAL(what, val)		printf("  %s: %d\n", what, val[0]*256 + val[1]);
 #define	SVAL(what, val)		printf("  %s: %s\n", what, val);
 
-static void
+static void 
 print_di(struct disk_info *dip)
 {
-static	char *ds_name[] = { "empty", "incomplete/appendable", "complete", "illegal" };
-static	char *ss_name[] = { "empty", "incomplete/appendable", "illegal", "complete", };
+	static	char *ds_name[] = { "empty", "incomplete/appendable", "complete", "illegal" };
+	static	char *ss_name[] = { "empty", "incomplete/appendable", "illegal", "complete", };
 
 	IS("erasable", dip->erasable);
 	printf("disk status: %s\n", ds_name[dip->disk_status]);
@@ -1733,7 +1737,7 @@
 	"Medium Type C, high Beta category (C+)",
 };
 
-static void
+static void 
 atip_printspeed(char *fmt, int speedindex, char speedtab[])
 {
 	printf("%s:", fmt);
@@ -1745,7 +1749,7 @@
 	}
 }
 
-static void
+static void 
 print_atip(SCSI *scgp, struct atipinfo *atp)
 {
 	char	*sub_type;
@@ -1837,7 +1841,7 @@
 }
 #endif	/* PRINT_ATIP */
 
-static int
+static int 
 speed_select_mmc(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	Uchar	mode[0x100];
@@ -1958,7 +1962,7 @@
  * the minimum write speed of the drive is higher. Try to increment
  * the write speed unti it gets accepted by the drive.
  */
-static int
+static int 
 mmc_set_speed(SCSI *scgp, int readspeed, int writespeed, int rotctl)
 {
 	int	rs;
@@ -2003,7 +2007,7 @@
 	return (ret);
 }
 
-static int
+static int 
 speed_select_mdvd(SCSI *scgp, cdr_t *dp, int *speedp)
 {
   int retcode;
@@ -2062,7 +2066,7 @@
    return retcode;
 }
 
-static int
+static int 
 next_wr_addr_mmc(SCSI *scgp, track_t *trackp, long *ap)
 {
 	struct	track_info	track_info;
@@ -2103,7 +2107,7 @@
 	return (0);
 }
 
-static int
+static int 
 write_leadin_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uint	i;
@@ -2192,7 +2196,7 @@
 	0,		/* 7			*/
 };
 
-static int
+static int 
 next_wr_addr_mdvd(SCSI *scgp, track_t *trackp, long *ap)
 {
 	int     track=0;
@@ -2232,7 +2236,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_track_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uchar	mode[0x100];
@@ -2309,7 +2313,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_track_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uchar	mode[0x100];
@@ -2345,7 +2349,7 @@
 	return (0);
 }
 
-static int
+static int 
 close_track_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	int	ret;
@@ -2368,7 +2372,7 @@
 	return (0);
 }
 
-static int
+static int 
 close_track_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	int	ret;
@@ -2399,7 +2403,7 @@
 	SES_DA_ROM,	/* Invalid - use default */
 };
 
-static int
+static int 
 open_session_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uchar	mode[0x100];
@@ -2468,7 +2472,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_session_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	Uchar	mode[0x100];
@@ -2543,7 +2547,7 @@
 	return (0);
 }
 
-static int
+static int 
 waitfix_mmc(SCSI *scgp, int secs)
 {
 	char	dibuf[16];
@@ -2567,7 +2571,7 @@
 #undef	W_SLEEP
 }
 
-static int
+static int 
 fixate_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	int	ret = 0;
@@ -2672,7 +2676,7 @@
 	return (ret);
 }
 
-static int
+static int 
 fixate_mdvd(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
       /*set a really BIG timeout and call fixate_mmc
@@ -2710,7 +2714,7 @@
 	"forced format",
 };
 
-static int
+static int 
 blank_mmc(SCSI *scgp, cdr_t *dp, long addr, int blanktype)
 {
 	BOOL	cdrr	 = FALSE;	/* Read CD-R	*/
@@ -2742,8 +2746,7 @@
 	return (ret);
 }
 
-static int
-format_mdvd(SCSI *scgp, cdr_t *dp, int formattype)
+static int format_mdvd(SCSI *scgp, cdr_t *dp, int formattype)
 {
 extern	char	*buf;
 	BOOL	dvdwr	 = FALSE;	/* Write DVD	*/
@@ -2813,7 +2816,7 @@
 	return (ret);
 }
 
-static int
+static int 
 send_opc_mmc(SCSI *scgp, caddr_t bp, int cnt, int doopc)
 {
 	int	ret;
@@ -2871,7 +2874,7 @@
 	return (0);
 }
 
-static int
+static int 
 opt1_mmc(SCSI *scgp, cdr_t *dp)
 {
 	int	oflags = dp->cdr_dstat->ds_cdrflags;
@@ -2952,7 +2955,7 @@
 	return (0);
 }
 
-static int
+static int 
 opt2_mmc(SCSI *scgp, cdr_t *dp)
 {
 	Uchar	mode[0x100];
@@ -3034,7 +3037,7 @@
 	return (0);
 }
 
-static int
+static int 
 opt1_mdvd(SCSI *scgp, cdr_t *dp)
 {
 	int	oflags = dp->cdr_dstat->ds_cdrflags;
@@ -3099,7 +3102,7 @@
 	0xFF,			/* 15 -    Vendor specific			*/
 };
 
-static int
+static int 
 gen_cue_mmc(track_t *trackp, void *vcuep, BOOL needgap)
 {
 	int	tracks = trackp->tracks;
@@ -3236,7 +3239,7 @@
 	return (ncue);
 }
 
-static void
+static void 
 fillcue(struct mmc_cue *cp  /* The target cue entry */, 
         int ca              /* Control/adr for this entry */, 
         int tno             /* Track number for this entry */, 
@@ -3255,7 +3258,7 @@
 	cp->cs_frame = mp->msf_frame;
 }
 
-static int
+static int 
 send_cue_mmc(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	struct mmc_cue	*cp;
@@ -3288,7 +3291,7 @@
 	return (ret);
 }
 
-static int
+static int 
 stats_mmc(SCSI *scgp, cdr_t *dp)
 {
 	Uchar mode[256];
@@ -3355,7 +3358,7 @@
 	return (0);
 }
 /*--------------------------------------------------------------------------*/
-static BOOL
+static BOOL 
 mmc_isplextor(SCSI *scgp)
 {
 	if (scgp->inq != NULL &&
@@ -3365,7 +3368,7 @@
 	return (FALSE);
 }
 
-static BOOL
+static BOOL 
 mmc_isyamaha(SCSI *scgp)
 {
 	if (scgp->inq != NULL &&
@@ -3375,7 +3378,7 @@
 	return (FALSE);
 }
 
-static void
+static void 
 do_varirec_plextor(SCSI *scgp)
 {
 	char	*p;
@@ -3414,7 +3417,7 @@
 	{ 0x00,	0,  NULL, },
 };
 
-static int
+static int 
 do_gigarec_plextor(SCSI *scgp)
 {
 	char	*p;
@@ -3443,7 +3446,7 @@
 	return (0);
 }
 
-static int
+static int 
 drivemode_plextor(SCSI *scgp, caddr_t bp, int cnt, int modecode, void *modeval)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -3489,9 +3492,8 @@
 #define	MBbb_SPEAD_READ	0x01	/* Spead Read				   */
 				/* Danach Speed auf 0xFFFF 0xFFFF setzen   */
 
-static int
-drivemode2_plextor(SCSI *scgp, caddr_t bp, int cnt, int modecode, 
-                   void *modeval)
+static int 
+drivemode2_plextor(SCSI *scgp, caddr_t bp, int cnt, int modecode, void *modeval)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -3522,7 +3524,7 @@
 	return (0);
 }
 
-static int
+static int 
 check_varirec_plextor(SCSI *scgp)
 {
 	int	modecode = 2;
@@ -3539,7 +3541,7 @@
 	return (0);
 }
 
-static int
+static int 
 check_gigarec_plextor(SCSI *scgp)
 {
 	int	modecode = 4;
@@ -3556,7 +3558,7 @@
 	return (0);
 }
 
-static int
+static int 
 varirec_plextor(SCSI *scgp, BOOL on, int val)
 {
 	int	modecode = 2;
@@ -3604,7 +3606,7 @@
 	return (0);
 }
 
-static int
+static int 
 gigarec_plextor(SCSI *scgp, int val)
 {
 	int	modecode = 4;
@@ -3651,7 +3653,7 @@
 	return (getmode[3]);
 }
 
-static Int32_t
+static Int32_t 
 gigarec_mult(int code, Int32_t val)
 {
 	Int32_t	add;
@@ -3668,7 +3670,7 @@
 	return (val + add);
 }
 
-static int
+static int 
 check_ss_hide_plextor(SCSI *scgp)
 {
 	int	modecode = 1;
@@ -3685,7 +3687,7 @@
 	return (getmode[2] & 0x03);
 }
 
-static int
+static int 
 check_speed_rd_plextor(SCSI *scgp)
 {
 	int	modecode = 0xBB;
@@ -3702,7 +3704,7 @@
 	return (getmode[2] & 0x01);
 }
 
-static int
+static int 
 check_powerrec_plextor(SCSI *scgp)
 {
 	int	modecode = 0;
@@ -3722,7 +3724,7 @@
 	return (0);
 }
 
-static int
+static int 
 ss_hide_plextor(SCSI *scgp, BOOL do_ss, BOOL do_hide)
 {
 	int	modecode = 1;
@@ -3784,7 +3786,7 @@
 	return (0);
 }
 
-static int
+static int 
 speed_rd_plextor(SCSI *scgp, BOOL do_speedrd)
 {
 	int	modecode = 0xBB;
@@ -3840,7 +3842,7 @@
 	return (0);
 }
 
-static int
+static int 
 powerrec_plextor(SCSI *scgp, BOOL do_powerrec)
 {
 	int	modecode = 0;
@@ -3895,7 +3897,7 @@
 	return (0);
 }
 
-static int
+static int 
 get_speeds_plextor(SCSI *scgp, int *selp, int *maxp, int *lastp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -3935,7 +3937,7 @@
 	return (0);
 }
 
-static int
+static int 
 bpc_plextor(SCSI *scgp, int mode, int *bpp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -3973,7 +3975,7 @@
 	return (0);
 }
 
-static int
+static int 
 set_audiomaster_yamaha(SCSI *scgp, cdr_t *dp, BOOL keep_mode)
 {
 	Uchar	mode[0x100];
@@ -4032,8 +4034,8 @@
 	return (ret);
 }
 
-struct ricoh_mode_page_30 *
-get_justlink_ricoh(SCSI *scgp, Uchar *mode)
+struct 
+ricoh_mode_page_30 *get_justlink_ricoh(SCSI *scgp, Uchar *mode)
 {
 	Uchar	modec[0x100];
 	int	len;
@@ -4076,7 +4078,7 @@
 	return (mp);
 }
 
-static int
+static int 
 force_speed_yamaha(SCSI *scgp, int readspeed, int writespeed)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -4158,7 +4160,7 @@
 	return (TRUE);
 }
 
-static int
+static int 
 do_tattoo_yamaha(SCSI *scgp, FILE *f)
 {
 	Int32_t ival = 0;
@@ -4236,8 +4238,8 @@
  * Yamaha specific version of 'write buffer' that offers an additional
  * Parameter Length 'parlen' parameter.
  */
-static int
-yamaha_write_buffer(SCSI *scgp, int mode, int bufferid, long offset, 
+static int 
+yamaha_write_buffer(SCSI *scgp, int mode, int bufferid, long offset,
                     long parlen, void *buffer, long buflen)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -4264,7 +4266,7 @@
 	return (0);
 }
 
-static int
+static int 
 dvd_dual_layer_split(SCSI *scgp, cdr_t *dp, long tsize)
 {
     unsigned char	xb[12];
@@ -4304,4 +4306,3 @@
     }
    return 1;
 }
-

Modified: nonameyet/branches/cleanup/cdrecord/drv_philips.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/drv_philips.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/drv_philips.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -54,38 +54,40 @@
 extern	int	debug;
 extern	int	lverbose;
 
-static	int	load_unload_philips		__PR((SCSI *scgp, int));
-static	int	philips_load			__PR((SCSI *scgp, cdr_t *dp));
-static	int	philips_unload			__PR((SCSI *scgp, cdr_t *dp));
-static	int	philips_dumbload		__PR((SCSI *scgp, cdr_t *dp));
-static	int	philips_dumbunload		__PR((SCSI *scgp, cdr_t *dp));
-static	int	plasmon_buf			__PR((SCSI *, long *, long *));
-static	int	recover_philips			__PR((SCSI *scgp, cdr_t *dp, int));
-static	int	speed_select_yamaha		__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	speed_select_philips		__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	speed_select_oldphilips		__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	speed_select_dumbphilips	__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	speed_select_pioneer		__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	philips_init			__PR((SCSI *scgp, cdr_t *dp));
-static	int	philips_getdisktype		__PR((SCSI *scgp, cdr_t *dp));
-static	BOOL	capacity_philips		__PR((SCSI *scgp, long *lp));
-static	int	first_writable_addr_philips	__PR((SCSI *scgp, long *, int, int, int, int));
-static	int	next_wr_addr_philips		__PR((SCSI *scgp, track_t *trackp, long *ap));
-static	int	reserve_track_philips		__PR((SCSI *scgp, unsigned long));
-static	int	scsi_cdr_write_philips		__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-static	int	write_track_info_philips	__PR((SCSI *scgp, int));
-static	int	write_track_philips		__PR((SCSI *scgp, long, int));
-static	int	open_track_philips		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	open_track_plasmon		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	open_track_oldphilips		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	open_track_yamaha		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	close_track_philips		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	fixation_philips		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
+static	int	load_unload_philips(SCSI *scgp, int);
+static	int	philips_load(SCSI *scgp, cdr_t *dp);
+static	int	philips_unload(SCSI *scgp, cdr_t *dp);
+static	int	philips_dumbload(SCSI *scgp, cdr_t *dp);
+static	int	philips_dumbunload(SCSI *scgp, cdr_t *dp);
+static	int	plasmon_buf(SCSI *, long *, long *);
+static	int	recover_philips(SCSI *scgp, cdr_t *dp, int);
+static	int	speed_select_yamaha(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	speed_select_philips(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	speed_select_oldphilips(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	speed_select_dumbphilips(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	speed_select_pioneer(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	philips_init(SCSI *scgp, cdr_t *dp);
+static	int	philips_getdisktype(SCSI *scgp, cdr_t *dp);
+static	BOOL	capacity_philips(SCSI *scgp, long *lp);
+static	int	first_writable_addr_philips(SCSI *scgp, long *, int, int, int, 
+														 int);
+static	int	next_wr_addr_philips(SCSI *scgp, track_t *trackp, long *ap);
+static	int	reserve_track_philips(SCSI *scgp, unsigned long);
+static	int	scsi_cdr_write_philips(SCSI *scgp, caddr_t bp, long sectaddr, 
+												  long size, int blocks, BOOL islast);
+static	int	write_track_info_philips(SCSI *scgp, int);
+static	int	write_track_philips(SCSI *scgp, long, int);
+static	int	open_track_philips(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	open_track_plasmon(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	open_track_oldphilips(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	open_track_yamaha(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	close_track_philips(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	fixation_philips(SCSI *scgp, cdr_t *dp, track_t *trackp);
 
-static	int	philips_attach			__PR((SCSI *scgp, cdr_t *));
-static	int	plasmon_attach			__PR((SCSI *scgp, cdr_t *));
-static	int	ricoh_attach			__PR((SCSI *scgp, cdr_t *));
-static	int	philips_getlilo			__PR((SCSI *scgp, long *lilenp, long *lolenp));
+static	int	philips_attach(SCSI *scgp, cdr_t *);
+static	int	plasmon_attach(SCSI *scgp, cdr_t *);
+static	int	ricoh_attach(SCSI *scgp, cdr_t *);
+static	int	philips_getlilo(SCSI *scgp, long *lilenp, long *lolenp);
 
 
 struct cdd_52x_mode_page_21 {	/* write track information */
@@ -161,12 +163,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_oldphilips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -174,7 +176,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -202,12 +204,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_oldphilips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -215,7 +217,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -243,12 +245,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_philips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -256,7 +258,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -285,12 +287,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_philips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -298,7 +300,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -326,12 +328,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_philips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -339,7 +341,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -367,12 +369,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_oldphilips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -380,7 +382,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -408,12 +410,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_plasmon,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -421,7 +423,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -449,13 +451,13 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 /*	open_track_yamaha,*/
 /*???*/	open_track_oldphilips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -463,7 +465,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -492,12 +494,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_yamaha,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -505,7 +507,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -534,12 +536,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_philips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -547,7 +549,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -576,12 +578,12 @@
 	next_wr_addr_philips,
 	reserve_track_philips,
 	scsi_cdr_write_philips,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
 	no_sendcue,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_philips,
 	close_track_philips,
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy,
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy,
 	cmd_dummy,
 	cmd_dummy,					/* abort	*/
 	read_session_offset_philips,
@@ -589,14 +591,13 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
 
 
-static int
-load_unload_philips(SCSI *scgp, int load)
+static int load_unload_philips(SCSI *scgp, int load)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -615,19 +616,19 @@
 	return (0);
 }
 
-static int
+static int 
 philips_load(SCSI *scgp, cdr_t *dp)
 {
 	return (load_unload_philips(scgp, 1));
 }
 
-static int
+static int 
 philips_unload(SCSI *scgp, cdr_t *dp)
 {
 	return (load_unload_philips(scgp, 0));
 }
 
-static int
+static int 
 philips_dumbload(SCSI *scgp, cdr_t *dp)
 {
 	int	ret;
@@ -640,7 +641,7 @@
 	return (0);
 }
 
-static int
+static int 
 philips_dumbunload(SCSI *scgp, cdr_t *dp)
 {
 	int	ret;
@@ -653,7 +654,7 @@
 	return (0);
 }
 
-static int
+static int 
 plasmon_buf(SCSI *scgp, 
             long *sp /* Size pointer */, 
             long *fp /* Free space pointer */)
@@ -676,7 +677,7 @@
 	return (100);	/* 100 % */
 }
 
-static int
+static int 
 recover_philips(SCSI *scgp, cdr_t *dp, int track)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -695,7 +696,7 @@
 	return (0);
 }
 
-static int
+static int 
 speed_select_yamaha(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	struct	scsi_mode_page_header	*mp;
@@ -742,7 +743,7 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
+static int 
 speed_select_philips(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	struct	scsi_mode_page_header	*mp;
@@ -788,7 +789,7 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
+static int 
 speed_select_pioneer(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	if (speedp != 0 && *speedp < 2) {
@@ -799,7 +800,7 @@
 	return (speed_select_philips(scgp, dp, speedp));
 }
 
-static int
+static int 
 speed_select_oldphilips(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	BOOL	dummy = (dp->cdr_cmdflags & F_DUMMY) != 0;
@@ -813,7 +814,7 @@
 	return (0);
 }
 
-static int
+static int 
 speed_select_dumbphilips(SCSI *scgp, cdr_t *dp, int *speedp)
 {
 	if (speed_select_philips(scgp, dp, speedp) < 0)
@@ -821,7 +822,7 @@
 	return (0);
 }
 
-static int
+static int 
 philips_init(SCSI *scgp, cdr_t *dp)
 {
 	return ((*dp->cdr_set_speed_dummy)(scgp, dp, NULL));
@@ -830,7 +831,7 @@
 
 #define	IS(what, flag)	printf("  Is %s%s\n", flag?"":"not ", what);
 
-static int
+static int 
 philips_getdisktype(SCSI *scgp, cdr_t *dp)
 {
 	dstat_t	*dsp = dp->cdr_dstat;
@@ -909,7 +910,7 @@
 	return (drive_getdisktype(scgp, dp));
 }
 
-static BOOL
+static BOOL 
 capacity_philips(SCSI *scgp, long *lp)
 {
 	long	l = 0L;
@@ -942,11 +943,11 @@
 	char	res;
 };
 
-static int
+static int 
 first_writable_addr_philips(SCSI *scgp, long *ap, int track, int isaudio, 
-                            int preemp, int npa)
+										int preemp, int npa)
 {
-		struct	fwa	fwa;
+	struct	fwa	fwa;
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
 	fillbytes((caddr_t)&fwa, sizeof (fwa), '\0');
@@ -974,7 +975,7 @@
 	return (0);
 }
 
-static int
+static int 
 next_wr_addr_philips(SCSI *scgp, track_t *trackp, long *ap)
 {
 
@@ -984,7 +985,7 @@
 	return (0);
 }
 
-static int
+static int 
 reserve_track_philips(SCSI *scgp, unsigned long len)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -1004,9 +1005,9 @@
 	return (0);
 }
 
-static int
+static int 
 scsi_cdr_write_philips(SCSI *scgp, 
-                       caddr_t bp       /* address of buffer */, 
+                       caddr_t bp       /* address of buffer */,
                        long sectaddr    /* disk address (sector) to put */,
                        long size        /* number of bytes to transfer */, 
                        int blocks       /* sector count */, 
@@ -1015,7 +1016,7 @@
 	return (write_xg0(scgp, bp, 0, size, blocks));
 }
 
-static int
+static int 
 write_track_info_philips(SCSI *scgp, int sectype)
 {
 	struct cdd_52x_mode_data md;
@@ -1032,9 +1033,10 @@
 	return (mode_select(scgp, (Uchar *)&md, count, 0, scgp->inq->data_format >= 2));
 }
 
-static int
-write_track_philips(SCSI *scgp, long track /* track number 0 == new track */, 
-                    int sectype)
+static int 
+write_track_philips(SCSI *scgp, 
+							long track /* track number 0 == new track */, 
+                    	int sectype)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1055,7 +1057,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_track_philips(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	if (select_secsize(scgp, trackp->secsize) < 0)
@@ -1070,7 +1072,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_track_plasmon(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	if (select_secsize(scgp, trackp->secsize) < 0)
@@ -1082,7 +1084,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_track_oldphilips(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	if (write_track_philips(scgp, 0, trackp->sectype) < 0)
@@ -1091,7 +1093,7 @@
 	return (0);
 }
 
-static int
+static int 
 open_track_yamaha(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	if (select_secsize(scgp, trackp->secsize) < 0)
@@ -1103,14 +1105,13 @@
 	return (0);
 }
 
-static int
+static int 
 close_track_philips(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	return (scsi_flush_cache(scgp, FALSE));
 }
 
-static int
-fixation_philips(SCSI *scgp, cdr_t *dp, track_t *trackp)
+static int fixation_philips(SCSI *scgp, cdr_t *dp, track_t *trackp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1285,14 +1286,14 @@
 	NULL
 };
 
-static int
+static int 
 philips_attach(SCSI *scgp, cdr_t *dp)
 {
 	scg_setnonstderrs(scgp, sd_cdd_521_error_str);
 	return (0);
 }
 
-static int
+static int 
 plasmon_attach(SCSI *scgp, cdr_t *dp)
 {
 	scgp->inq->data_format = 1;	/* Correct the ly */
@@ -1301,7 +1302,7 @@
 	return (0);
 }
 
-static int
+static int 
 ricoh_attach(SCSI *scgp, cdr_t *dp)
 {
 	if (dp == &cdr_ricoh_ro1060) {
@@ -1312,11 +1313,11 @@
 	return (0);
 }
 
-static int
+static int 
 philips_getlilo(SCSI *scgp, long *lilenp, long *lolenp)
 {
-		char	buf[4];
-		long	li, lo;
+	char	buf[4];
+	long	li, lo;
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
 	fillbytes((caddr_t)scmd, sizeof (*scmd), '\0');

Modified: nonameyet/branches/cleanup/cdrecord/drv_simul.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/drv_simul.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/drv_simul.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -64,28 +64,27 @@
 extern	int	verbose;
 extern	int	lverbose;
 
-static	int	simul_load		__PR((SCSI *scgp, cdr_t *));
-static	int	simul_unload		__PR((SCSI *scgp, cdr_t *));
-static	cdr_t	*identify_simul		__PR((SCSI *scgp, cdr_t *, struct scsi_inquiry *));
-static	int	init_simul		__PR((SCSI *scgp, cdr_t *dp));
-static	int	getdisktype_simul	__PR((SCSI *scgp, cdr_t *dp));
-static	int	speed_select_simul	__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	next_wr_addr_simul	__PR((SCSI *scgp, track_t *trackp, long *ap));
-static	int	cdr_write_simul		__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-static	int	open_track_simul	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	close_track_simul	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	open_session_simul	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	fixate_simul		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	void	tv_sub			__PR((struct timeval *tvp1, struct timeval *tvp2));
+static	int	simul_load(SCSI *scgp, cdr_t *);
+static	int	simul_unload(SCSI *scgp, cdr_t *);
+static	cdr_t	*identify_simul(SCSI *scgp, cdr_t *, struct scsi_inquiry *);
+static	int	init_simul(SCSI *scgp, cdr_t *dp);
+static	int	getdisktype_simul(SCSI *scgp, cdr_t *dp);
+static	int	speed_select_simul(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	next_wr_addr_simul(SCSI *scgp, track_t *trackp, long *ap);
+static	int	cdr_write_simul(SCSI *scgp, caddr_t bp, long sectaddr, long size, 
+										 int blocks, BOOL islast);
+static	int	open_track_simul(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	close_track_simul(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	open_session_simul(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	fixate_simul(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	void	tv_sub(struct timeval *tvp1, struct timeval *tvp2);
 
-static int
-simul_load(SCSI *scgp, cdr_t *dp)
+static int simul_load(SCSI *scgp, cdr_t *dp)
 {
 	return (0);
 }
 
-static int
-simul_unload(SCSI *scgp, cdr_t *dp)
+static int simul_unload(SCSI *scgp, cdr_t *dp)
 {
 	return (0);
 }
@@ -107,15 +106,15 @@
 	simul_unload,
 	buf_dummy,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_simul,
 	select_secsize,
 	next_wr_addr_simul,
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	cdr_write_simul,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy, /* send_cue */
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy, /* send_cue */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_simul,
 	close_track_simul,
 	open_session_simul,
@@ -126,7 +125,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };
@@ -148,15 +147,15 @@
 	simul_unload,
 	buf_dummy,
 	cmd_dummy,					/* recovery_needed */
-	(int(*)__PR((SCSI *, cdr_t *, int)))cmd_dummy,	/* recover	*/
+	(int(*)(SCSI *, cdr_t *, int))cmd_dummy,	/* recover	*/
 	speed_select_simul,
 	select_secsize,
 	next_wr_addr_simul,
-	(int(*)__PR((SCSI *, Ulong)))cmd_ill,	/* reserve_track	*/
+	(int(*)(SCSI *, Ulong))cmd_ill,	/* reserve_track	*/
 	cdr_write_simul,
-	(int(*)__PR((track_t *, void *, BOOL)))cmd_dummy,	/* gen_cue */
-	(int(*)__PR((SCSI *scgp, cdr_t *, track_t *)))cmd_dummy, /* send_cue */
-	(int(*)__PR((SCSI *, cdr_t *, track_t *)))cmd_dummy, /* leadin */
+	(int(*)(track_t *, void *, BOOL))cmd_dummy,	/* gen_cue */
+	(int(*)(SCSI *scgp, cdr_t *, track_t *))cmd_dummy, /* send_cue */
+	(int(*)(SCSI *, cdr_t *, track_t *))cmd_dummy, /* leadin */
 	open_track_simul,
 	close_track_simul,
 	open_session_simul,
@@ -167,7 +166,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };

Modified: nonameyet/branches/cleanup/cdrecord/drv_sony.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/drv_sony.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/drv_sony.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -212,37 +212,41 @@
 
 #define	strbeg(s1, s2)	(strstr((s2), (s1)) == (s2))
 
-static	int	write_start_sony	__PR((SCSI *scgp, caddr_t bp, int size));
-static	int	write_continue_sony	__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-static	int	discontinue_sony	__PR((SCSI *scgp));
-static	int	write_track_sony	__PR((SCSI *scgp, long track, int sectype));
-static	int	close_track_sony	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	flush_sony		__PR((SCSI *scgp, int track));
-static	int	finalize_sony		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	recover_sony		__PR((SCSI *scgp, cdr_t *dp, int track));
-static	int	set_wr_parameter_sony	__PR((SCSI *scgp, caddr_t bp, int size));
-static	int	next_wr_addr_sony	__PR((SCSI *scgp, track_t *trackp, long *ap));
-static	int	reserve_track_sony	__PR((SCSI *scgp, unsigned long len));
-static	int	init_sony		__PR((SCSI *scgp, cdr_t *dp));
-static	int	getdisktype_sony	__PR((SCSI *scgp, cdr_t *dp));
-static	void	di_to_dstat_sony	__PR((struct sony_924_mode_page_22 *dip, dstat_t *dsp));
-static	int	speed_select_sony	__PR((SCSI *scgp, cdr_t *dp, int *speedp));
-static	int	next_writable_address_sony __PR((SCSI *scgp, long *ap, int track, int sectype, int tracktype));
-static	int	new_track_sony		__PR((SCSI *scgp, int track, int sectype, int tracktype));
-static	int	open_track_sony		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	open_session_sony	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	abort_session_sony	__PR((SCSI *scgp, cdr_t *dp));
-static	int	get_page22_sony		__PR((SCSI *scgp, char *mode));
-static	int	gen_cue_sony		__PR((track_t *trackp, void *vcuep, BOOL needgap));
-static	void	fillcue			__PR((struct sony_cue *cp, int ca, int tno, int idx, int dataform, int scms, msf_t *mp));
-static	int	send_cue_sony		__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	write_leadin_sony	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-static	int	sony_attach		__PR((SCSI *scgp, cdr_t *dp));
+static	int	write_start_sony(SCSI *scgp, caddr_t bp, int size);
+static	int	write_continue_sony(SCSI *scgp, caddr_t bp, long sectaddr, 
+											  long size, int blocks, BOOL islast);
+static	int	discontinue_sony(SCSI *scgp);
+static	int	write_track_sony(SCSI *scgp, long track, int sectype);
+static	int	close_track_sony(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	flush_sony(SCSI *scgp, int track);
+static	int	finalize_sony(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	recover_sony(SCSI *scgp, cdr_t *dp, int track);
+static	int	set_wr_parameter_sony(SCSI *scgp, caddr_t bp, int size);
+static	int	next_wr_addr_sony(SCSI *scgp, track_t *trackp, long *ap);
+static	int	reserve_track_sony(SCSI *scgp, unsigned long len);
+static	int	init_sony(SCSI *scgp, cdr_t *dp);
+static	int	getdisktype_sony(SCSI *scgp, cdr_t *dp);
+static	void	di_to_dstat_sony(struct sony_924_mode_page_22 *dip, 
+										  dstat_t *dsp);
+static	int	speed_select_sony(SCSI *scgp, cdr_t *dp, int *speedp);
+static	int	next_writable_address_sony(SCSI *scgp, long *ap, int track, 
+														int sectype, int tracktype);
+static	int	new_track_sony(SCSI *scgp, int track, int sectype, 
+										int tracktype);
+static	int	open_track_sony(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	open_session_sony(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	abort_session_sony(SCSI *scgp, cdr_t *dp);
+static	int	get_page22_sony(SCSI *scgp, char *mode);
+static	int	gen_cue_sony(track_t *trackp, void *vcuep, BOOL needgap);
+static	void	fillcue(struct sony_cue *cp, int ca, int tno, int idx, int dataform, int scms, msf_t *mp);
+static	int	send_cue_sony(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	write_leadin_sony(SCSI *scgp, cdr_t *dp, track_t *trackp);
+static	int	sony_attach(SCSI *scgp, cdr_t *dp);
 #ifdef	SONY_DEBUG
-static	void	print_sony_mp22		__PR((struct sony_924_mode_page_22 *xp, int len));
-static	void	print_sony_mp23		__PR((struct sony_924_mode_page_23 *xp, int len));
+static	void	print_sony_mp22(struct sony_924_mode_page_22 *xp, int len);
+static	void	print_sony_mp23(struct sony_924_mode_page_23 *xp, int len);
 #endif
-static	int	buf_cap_sony		__PR((SCSI *scgp, long *, long *));
+static	int	buf_cap_sony(SCSI *scgp, long *, long *);
 
 cdr_t	cdr_sony_cdu924 = {
 	0, 0,
@@ -280,7 +284,7 @@
 	cmd_dummy,					/* stats	*/
 	blank_dummy,
 	format_dummy,
-	(int(*)__PR((SCSI *, caddr_t, int, int)))NULL,	/* no OPC	*/
+	(int(*)(SCSI *, caddr_t, int, int))NULL,	/* no OPC	*/
 	cmd_dummy,					/* opt1		*/
 	cmd_dummy,					/* opt2		*/
 };

Modified: nonameyet/branches/cleanup/cdrecord/fifo.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/fifo.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/fifo.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -183,36 +183,36 @@
 extern	int	debug;
 extern	int	lverbose;
 
-void	init_fifo	__PR((long));
+void	init_fifo(long);
 #ifdef	USE_MMAP
-static	char	*mkshare	__PR((int size));
+static	char	*mkshare(int size);
 #endif
 #ifdef	USE_USGSHM
-static	char	*mkshm		__PR((int size));
+static	char	*mkshm(int size);
 #endif
 #ifdef	USE_OS2SHM
-static	char	*mkos2shm	__PR((int size));
+static	char	*mkos2shm(int size);
 #endif
 #ifdef	USE_BEOS_AREAS
-static	char	*mkbeosshm	__PR((int size));
-static	void	beosshm_child	__PR((void));
+static	char	*mkbeosshm(int size);
+static	void	beosshm_child(void);
 #endif
 
-BOOL	init_faio	__PR((track_t *trackp, int));
-BOOL	await_faio	__PR((void));
-void	kill_faio	__PR((void));
-int	wait_faio	__PR((void));
-static	void	faio_reader	__PR((track_t *trackp));
-static	void	faio_read_track	__PR((track_t *trackp));
-static	void	faio_wait_on_buffer __PR((faio_t *f, fowner_t s,
-					unsigned long delay,
-					unsigned long max_wait));
-static	int	faio_read_segment __PR((int fd, faio_t *f, track_t *track, long secno, int len));
-static	faio_t	*faio_ref	__PR((int n));
-int	faio_read_buf	__PR((int f, char *bp, int size));
-int	faio_get_buf	__PR((int f, char **bpp, int size));
-void	fifo_stats	__PR((void));
-int	fifo_percent	__PR((BOOL addone));
+BOOL	init_faio(track_t *trackp, int);
+BOOL	await_faio(void);
+void	kill_faio(void);
+int	wait_faio(void);
+static	void	faio_reader(track_t *trackp);
+static	void	faio_read_track(track_t *trackp);
+static	void	faio_wait_on_buffer(faio_t *f, fowner_t s, unsigned long delay,
+											  unsigned long max_wait);
+static	int	faio_read_segment(int fd, faio_t *f, track_t *track, long secno, 
+											int len);
+static	faio_t	*faio_ref(int n);
+int	faio_read_buf(int f, char *bp, int size);
+int	faio_get_buf(int f, char **bpp, int size);
+void	fifo_stats(void);
+int	fifo_percent(BOOL addone);
 
 
 void
@@ -832,15 +832,15 @@
 
 #include "cdrecord.h"
 
-void	init_fifo	__PR((long));
-BOOL	init_faio	__PR((track_t *track, int));
-BOOL	await_faio	__PR((void));
-void	kill_faio	__PR((void));
-int	wait_faio	__PR((void));
-int	faio_read_buf	__PR((int f, char *bp, int size));
-int	faio_get_buf	__PR((int f, char **bpp, int size));
-void	fifo_stats	__PR((void));
-int	fifo_percent	__PR((BOOL addone));
+void	init_fifo(long);
+BOOL	init_faio(track_t *track, int);
+BOOL	await_faio(void);
+void	kill_faio(void);
+int	wait_faio(void);
+int	faio_read_buf(int f, char *bp, int size);
+int	faio_get_buf(int f, char **bpp, int size);
+void	fifo_stats(void);
+int	fifo_percent(BOOL addone);
 
 
 void init_fifo(long fs)

Modified: nonameyet/branches/cleanup/cdrecord/getnum.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/getnum.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/getnum.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -40,9 +40,9 @@
 #include <utypes.h>
 #include <schily.h>
 
-static	Llong	number		__PR((char *arg, int *retp));
-int	getnum		__PR((char *arg, long *valp));
-int	getllnum	__PR((char *arg, Llong *lvalp));
+static	Llong	number(char *arg, int *retp);
+int	getnum(char *arg, long *valp);
+int	getllnum(char *arg, Llong *lvalp);
 
 static Llong
 number(register char *arg, int *retp)

Modified: nonameyet/branches/cleanup/cdrecord/isosize.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/isosize.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/isosize.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -43,7 +43,7 @@
 #include "iso9660.h"
 #include "cdrecord.h"	/* to verify isosize() prototype */
 
-Llong	isosize		__PR((int f));
+Llong	isosize(int f);
 
 Llong
 isosize(int f)

Modified: nonameyet/branches/cleanup/cdrecord/misc.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/misc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/misc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -41,10 +41,8 @@
 #include <standard.h>
 #include <schily.h>
 
-void	timevaldiff	__PR((struct timeval *start, struct timeval *stop));
-void	prtimediff	__PR((const char *fmt,
-					struct timeval *start,
-					struct timeval *stop));
+void	timevaldiff(struct timeval *start, struct timeval *stop);
+void	prtimediff(const char *fmt, struct timeval *start, struct timeval *stop);
 
 void
 timevaldiff(struct timeval *start, struct timeval *stop)

Modified: nonameyet/branches/cleanup/cdrecord/modes.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/modes.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/modes.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -47,13 +47,11 @@
 
 int	scsi_compliant;
 
-static	BOOL	has_mode_page	__PR((SCSI *scgp, int page, char *pagename, int *lenp));
-BOOL	get_mode_params	__PR((SCSI *scgp, int page, char *pagename,
-					Uchar *modep, Uchar *cmodep,
-					Uchar *dmodep, Uchar *smodep,
-					int *lenp));
-BOOL	set_mode_params	__PR((SCSI *scgp, char *pagename, Uchar *modep,
-					int len, int save, int secsize));
+static	BOOL	has_mode_page(SCSI *scgp, int page, char *pagename, int *lenp);
+BOOL	get_mode_params(SCSI *scgp, int page, char *pagename, Uchar *modep, 
+							 Uchar *cmodep, Uchar *dmodep, Uchar *smodep, int *lenp);
+BOOL	set_mode_params(SCSI *scgp, char *pagename, Uchar *modep, int len, 
+							 int save, int secsize);
 
 #define	XXX
 

Modified: nonameyet/branches/cleanup/cdrecord/movesect.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/movesect.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/movesect.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -41,7 +41,7 @@
 #include "cdrecord.h"
 #include "movesect.h"
 
-void	scatter_secs	__PR((track_t *trackp, char *bp, int nsecs));
+void	scatter_secs(track_t *trackp, char *bp, int nsecs);
 
 /*
  * Scatter input sector size records over buffer to make them

Modified: nonameyet/branches/cleanup/cdrecord/movesect.h
===================================================================
--- nonameyet/branches/cleanup/cdrecord/movesect.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/movesect.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -40,6 +40,6 @@
 #define	fill2048(p, val)	fillbytes(p, 2048, val)
 #define	fill96(p, val)		fillbytes(p, 96, val)
 
-extern	void	scatter_secs	__PR((track_t *trackp, char *bp, int nsecs));
+extern	void	scatter_secs(track_t *trackp, char *bp, int nsecs);
 
 #endif

Modified: nonameyet/branches/cleanup/cdrecord/scsi_cdr.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/scsi_cdr.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/scsi_cdr.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -74,94 +74,95 @@
 
 #define	strbeg(s1, s2)	(strstr((s2), (s1)) == (s2))
 
-BOOL	unit_ready	__PR((SCSI *scgp));
-BOOL	wait_unit_ready	__PR((SCSI *scgp, int secs));
-BOOL	scsi_in_progress __PR((SCSI *scgp));
-BOOL	cdr_underrun	__PR((SCSI *scgp));
-int	test_unit_ready	__PR((SCSI *scgp));
-int	rezero_unit	__PR((SCSI *scgp));
-int	request_sense	__PR((SCSI *scgp));
-int	request_sense_b	__PR((SCSI *scgp, caddr_t bp, int cnt));
-int	inquiry		__PR((SCSI *scgp, caddr_t, int));
-int	read_capacity	__PR((SCSI *scgp));
-void	print_capacity	__PR((SCSI *scgp, FILE *f));
-int	scsi_load_unload __PR((SCSI *scgp, int));
-int	scsi_prevent_removal __PR((SCSI *scgp, int));
-int	scsi_start_stop_unit __PR((SCSI *scgp, int, int, BOOL immed));
-int	scsi_set_speed	__PR((SCSI *scgp, int readspeed, int writespeed, int rotctl));
-int	scsi_get_speed	__PR((SCSI *scgp, int *readspeedp, int *writespeedp));
-int	qic02		__PR((SCSI *scgp, int));
-int	write_xscsi	__PR((SCSI *scgp, caddr_t, long, long, int));
-int	write_xg0	__PR((SCSI *scgp, caddr_t, long, long, int));
-int	write_xg1	__PR((SCSI *scgp, caddr_t, long, long, int));
-int	write_xg5	__PR((SCSI *scgp, caddr_t, long, long, int));
-int	seek_scsi	__PR((SCSI *scgp, long addr));
-int	seek_g0		__PR((SCSI *scgp, long addr));
-int	seek_g1		__PR((SCSI *scgp, long addr));
-int	scsi_flush_cache __PR((SCSI *scgp, BOOL immed));
-int	read_buffer	__PR((SCSI *scgp, caddr_t bp, int cnt, int mode));
-int	write_buffer	__PR((SCSI *scgp, char *buffer, long length, int mode, int bufferid, long offset));
-int	read_subchannel	__PR((SCSI *scgp, caddr_t bp, int track,
-					int cnt, int msf, int subq, int fmt));
-int	read_toc	__PR((SCSI *scgp, caddr_t, int, int, int, int));
-int	read_toc_philips __PR((SCSI *scgp, caddr_t, int, int, int, int));
-int	read_header	__PR((SCSI *scgp, caddr_t, long, int, int));
-int	read_disk_info	__PR((SCSI *scgp, caddr_t, int));
-int	read_track_info	__PR((SCSI *scgp, caddr_t, int type, int addr, int cnt));
-int	read_rzone_info	__PR((SCSI *scgp, caddr_t bp, int cnt));
-int	reserve_tr_rzone __PR((SCSI *scgp, long size));
-int	read_dvd_structure __PR((SCSI *scgp, caddr_t bp, int cnt, int addr, int layer, int fmt));
-int	send_dvd_structure __PR((SCSI *scgp, caddr_t bp, int cnt, int layer, int fmt));
-int	send_opc	__PR((SCSI *scgp, caddr_t, int cnt, int doopc));
-int	read_track_info_philips	__PR((SCSI *scgp, caddr_t, int, int));
-int	scsi_close_tr_session __PR((SCSI *scgp, int type, int track, BOOL immed));
-int	read_master_cue	__PR((SCSI *scgp, caddr_t bp, int sheet, int cnt));
-int	send_cue_sheet	__PR((SCSI *scgp, caddr_t bp, long size));
-int	read_buff_cap	__PR((SCSI *scgp, long *, long *));
-int	scsi_blank	__PR((SCSI *scgp, long addr, int blanktype, BOOL immed));
-int	scsi_format	__PR((SCSI *scgp, caddr_t addr, int size, BOOL background));
-int	scsi_set_streaming	__PR((SCSI *scgp, caddr_t addr, int size));
-BOOL	allow_atapi	__PR((SCSI *scgp, BOOL new));
-int	mode_select	__PR((SCSI *scgp, Uchar *, int, int, int));
-int	mode_sense	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-int	mode_select_sg0	__PR((SCSI *scgp, Uchar *, int, int, int));
-int	mode_sense_sg0	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-int	mode_select_g0	__PR((SCSI *scgp, Uchar *, int, int, int));
-int	mode_select_g1	__PR((SCSI *scgp, Uchar *, int, int, int));
-int	mode_sense_g0	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-int	mode_sense_g1	__PR((SCSI *scgp, Uchar *dp, int cnt, int page, int pcf));
-int	read_tochdr	__PR((SCSI *scgp, cdr_t *, int *, int *));
-int	read_cdtext	__PR((SCSI *scgp));
-int	read_trackinfo	__PR((SCSI *scgp, int, long *, struct msf *, int *, int *, int *));
-int	read_B0		__PR((SCSI *scgp, BOOL isbcd, long *b0p, long *lop));
-int	read_session_offset __PR((SCSI *scgp, long *));
-int	read_session_offset_philips __PR((SCSI *scgp, long *));
-int	sense_secsize	__PR((SCSI *scgp, int current));
-int	select_secsize	__PR((SCSI *scgp, int));
-BOOL	is_cddrive	__PR((SCSI *scgp));
-BOOL	is_unknown_dev	__PR((SCSI *scgp));
-int	read_scsi	__PR((SCSI *scgp, caddr_t, long, int));
-int	read_g0		__PR((SCSI *scgp, caddr_t, long, int));
-int	read_g1		__PR((SCSI *scgp, caddr_t, long, int));
-BOOL	getdev		__PR((SCSI *scgp, BOOL));
-void	printinq	__PR((SCSI *scgp, FILE *f));
-void	printdev	__PR((SCSI *scgp));
-BOOL	do_inquiry	__PR((SCSI *scgp, BOOL));
-BOOL	recovery_needed	__PR((SCSI *scgp, cdr_t *));
-int	scsi_load	__PR((SCSI *scgp, cdr_t *));
-int	scsi_unload	__PR((SCSI *scgp, cdr_t *));
-int	scsi_cdr_write	__PR((SCSI *scgp, caddr_t bp, long sectaddr, long size, int blocks, BOOL islast));
-struct cd_mode_page_2A * mmc_cap __PR((SCSI *scgp, Uchar *modep));
-void	mmc_getval	__PR((struct cd_mode_page_2A *mp,
-					BOOL *cdrrp, BOOL *cdwrp,
-					BOOL *cdrrwp, BOOL *cdwrwp,
-					BOOL *dvdp, BOOL *dvdwp));
-BOOL	is_mmc		__PR((SCSI *scgp, BOOL *cdwp, BOOL *dvdwp));
-BOOL	mmc_check	__PR((SCSI *scgp, BOOL *cdrrp, BOOL *cdwrp,
-					BOOL *cdrrwp, BOOL *cdwrwp,
-					BOOL *dvdp, BOOL *dvdwp));
-static	void	print_speed	__PR((char *fmt, int val));
-void	print_capabilities __PR((SCSI *scgp));
+BOOL	unit_ready(SCSI *scgp);
+BOOL	wait_unit_ready(SCSI *scgp, int secs);
+BOOL	scsi_in_progress(SCSI *scgp);
+BOOL	cdr_underrun(SCSI *scgp);
+int	test_unit_ready(SCSI *scgp);
+int	rezero_unit(SCSI *scgp);
+int	request_sense(SCSI *scgp);
+int	request_sense_b(SCSI *scgp, caddr_t bp, int cnt);
+int	inquiry(SCSI *scgp, caddr_t, int);
+int	read_capacity(SCSI *scgp);
+void	print_capacity(SCSI *scgp, FILE *f);
+int	scsi_load_unload(SCSI *scgp, int);
+int	scsi_prevent_removal(SCSI *scgp, int);
+int	scsi_start_stop_unit(SCSI *scgp, int, int, BOOL immed);
+int	scsi_set_speed(SCSI *scgp, int readspeed, int writespeed, int rotctl);
+int	scsi_get_speed(SCSI *scgp, int *readspeedp, int *writespeedp);
+int	qic02(SCSI *scgp, int);
+int	write_xscsi(SCSI *scgp, caddr_t, long, long, int);
+int	write_xg0(SCSI *scgp, caddr_t, long, long, int);
+int	write_xg1(SCSI *scgp, caddr_t, long, long, int);
+int	write_xg5(SCSI *scgp, caddr_t, long, long, int);
+int	seek_scsi(SCSI *scgp, long addr);
+int	seek_g0(SCSI *scgp, long addr);
+int	seek_g1(SCSI *scgp, long addr);
+int	scsi_flush_cache(SCSI *scgp, BOOL immed);
+int	read_buffer(SCSI *scgp, caddr_t bp, int cnt, int mode);
+int	write_buffer(SCSI *scgp, char *buffer, long length, int mode, 
+						 int bufferid, long offset);
+int	read_subchannel(SCSI *scgp, caddr_t bp, int track, int cnt, int msf, 
+							 int subq, int fmt);
+int	read_toc(SCSI *scgp, caddr_t, int, int, int, int);
+int	read_toc_philips(SCSI *scgp, caddr_t, int, int, int, int);
+int	read_header(SCSI *scgp, caddr_t, long, int, int);
+int	read_disk_info(SCSI *scgp, caddr_t, int);
+int	read_track_info(SCSI *scgp, caddr_t, int type, int addr, int cnt);
+int	read_rzone_info(SCSI *scgp, caddr_t bp, int cnt);
+int	reserve_tr_rzone(SCSI *scgp, long size);
+int	read_dvd_structure(SCSI *scgp, caddr_t bp, int cnt, int addr, int layer, 
+								 int fmt);
+int	send_dvd_structure(SCSI *scgp, caddr_t bp, int cnt, int layer, int fmt);
+int	send_opc(SCSI *scgp, caddr_t, int cnt, int doopc);
+int	read_track_info_philips(SCSI *scgp, caddr_t, int, int);
+int	scsi_close_tr_session(SCSI *scgp, int type, int track, BOOL immed);
+int	read_master_cue(SCSI *scgp, caddr_t bp, int sheet, int cnt);
+int	send_cue_sheet(SCSI *scgp, caddr_t bp, long size);
+int	read_buff_cap(SCSI *scgp, long *, long *);
+int	scsi_blank(SCSI *scgp, long addr, int blanktype, BOOL immed);
+int	scsi_format(SCSI *scgp, caddr_t addr, int size, BOOL background);
+int	scsi_set_streaming(SCSI *scgp, caddr_t addr, int size);
+BOOL	allow_atapi(SCSI *scgp, BOOL new);
+int	mode_select(SCSI *scgp, Uchar *, int, int, int);
+int	mode_sense(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+int	mode_select_sg0(SCSI *scgp, Uchar *, int, int, int);
+int	mode_sense_sg0(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+int	mode_select_g0(SCSI *scgp, Uchar *, int, int, int);
+int	mode_select_g1(SCSI *scgp, Uchar *, int, int, int);
+int	mode_sense_g0(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+int	mode_sense_g1(SCSI *scgp, Uchar *dp, int cnt, int page, int pcf);
+int	read_tochdr(SCSI *scgp, cdr_t *, int *, int *);
+int	read_cdtext(SCSI *scgp);
+int	read_trackinfo(SCSI *scgp, int, long *, struct msf *, int *, int *, 
+							int *);
+int	read_B0(SCSI *scgp, BOOL isbcd, long *b0p, long *lop);
+int	read_session_offset(SCSI *scgp, long *);
+int	read_session_offset_philips(SCSI *scgp, long *);
+int	sense_secsize(SCSI *scgp, int current);
+int	select_secsize(SCSI *scgp, int);
+BOOL	is_cddrive(SCSI *scgp);
+BOOL	is_unknown_dev(SCSI *scgp);
+int	read_scsi(SCSI *scgp, caddr_t, long, int);
+int	read_g0(SCSI *scgp, caddr_t, long, int);
+int	read_g1(SCSI *scgp, caddr_t, long, int);
+BOOL	getdev(SCSI *scgp, BOOL);
+void	printinq(SCSI *scgp, FILE *f);
+void	printdev(SCSI *scgp);
+BOOL	do_inquiry(SCSI *scgp, BOOL);
+BOOL	recovery_needed(SCSI *scgp, cdr_t *);
+int	scsi_load(SCSI *scgp, cdr_t *);
+int	scsi_unload(SCSI *scgp, cdr_t *);
+int	scsi_cdr_write(SCSI *scgp, caddr_t bp, long sectaddr, long size, 
+							int blocks, BOOL islast);
+struct cd_mode_page_2A * mmc_cap(SCSI *scgp, Uchar *modep);
+void	mmc_getval(struct cd_mode_page_2A *mp, BOOL *cdrrp, BOOL *cdwrp, 
+					  BOOL *cdrrwp, BOOL *cdwrwp, BOOL *dvdp, BOOL *dvdwp);
+BOOL	is_mmc(SCSI *scgp, BOOL *cdwp, BOOL *dvdwp);
+BOOL	mmc_check(SCSI *scgp, BOOL *cdrrp, BOOL *cdwrp, BOOL *cdrrwp, 
+					 BOOL *cdwrwp, BOOL *dvdp, BOOL *dvdwp);
+static	void	print_speed(char *fmt, int val);
+void	print_capabilities(SCSI *scgp);
 
 BOOL
 unit_ready(SCSI *scgp)
@@ -609,7 +610,8 @@
 
 #define	G0_MAXADDR	0x1FFFFFL
 
-int write_xscsi(SCSI *scgp, caddr_t bp, long addr, long size, int cnt)
+int 
+write_xscsi(SCSI *scgp, caddr_t bp, long addr, long size, int cnt)
 {
 	if (addr <= G0_MAXADDR)
 		return (write_xg0(scgp, bp, addr, size, cnt));
@@ -617,11 +619,12 @@
 		return (write_xg1(scgp, bp, addr, size, cnt));
 }
 
-int write_xg0(SCSI *scgp, 
-              caddr_t bp    /* address of buffer */, 
-              long addr     /* disk address (sector) to put */, 
-              long size     /* number of bytes to transfer */, 
-              int cnt       /* sectorcount */)
+int 
+write_xg0(SCSI *scgp, 
+          caddr_t bp    /* address of buffer */, 
+          long addr     /* disk address (sector) to put */, 
+          long size     /* number of bytes to transfer */, 
+          int cnt       /* sectorcount */)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -644,11 +647,12 @@
 	return (size - scg_getresid(scgp));
 }
 
-int write_xg1(SCSI *scgp, 
-              caddr_t bp    /* address of buffer */, 
-              long addr     /* disk address (sector) to put */, 
-              long size     /* number of bytes to transfer */, 
-              int cnt       /* sectorcount */)
+int 
+write_xg1(SCSI *scgp, 
+          caddr_t bp    /* address of buffer */, 
+          long addr     /* disk address (sector) to put */, 
+          long size     /* number of bytes to transfer */, 
+          int cnt       /* sectorcount */)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -671,11 +675,12 @@
 	return (size - scg_getresid(scgp));
 }
 
-int write_xg5(SCSI *scgp,
-              caddr_t bp    /* address of buffer */, 
-              long addr     /* disk address (sector) to put */, 
-              long size     /* number of bytes to transfer */, 
-              int cnt       /* sectorcount */)
+int 
+write_xg5(SCSI *scgp,
+          caddr_t bp    /* address of buffer */, 
+          long addr     /* disk address (sector) to put */, 
+          long size     /* number of bytes to transfer */, 
+          int cnt       /* sectorcount */)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -821,8 +826,8 @@
 }
 
 int
-read_subchannel(SCSI *scgp, caddr_t bp, int track, int cnt, int msf, 
-                int subq, int fmt)
+read_subchannel(SCSI *scgp, caddr_t bp, int track, int cnt, int msf, int subq, 
+					 int fmt)
 
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -1010,8 +1015,7 @@
 }
 
 int
-reserve_tr_rzone(SCSI *scgp, 
-                 long size /* number of blocks */)
+reserve_tr_rzone(SCSI *scgp, long size /* number of blocks */)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1681,8 +1685,8 @@
 }
 
 int
-read_trackinfo(SCSI *scgp, int track, long *offp, struct msf *msfp, 
-               int *adrp, int *controlp, int *modep)
+read_trackinfo(SCSI *scgp, int track, long *offp, struct msf *msfp, int *adrp, 
+					int *controlp, int *modep)
 {
 	struct	diskinfo *dp;
 	char	xb[256];
@@ -2621,12 +2625,13 @@
 	return (scsi_start_stop_unit(scgp, 0, 1, dp && (dp->cdr_cmdflags&F_IMMED)));
 }
 
-int scsi_cdr_write(SCSI *scgp, 
-                   caddr_t bp       /* address of buffer */, 
-                   long sectaddr    /* disk address (sector) to put */, 
-                   long size        /* number of bytes to transfer */, 
-                   int blocks       /* sector count */, 
-                   BOOL islast      /* last write for track */)
+int 
+scsi_cdr_write(SCSI *scgp, 
+               caddr_t bp       /* address of buffer */, 
+               long sectaddr    /* disk address (sector) to put */, 
+               long size        /* number of bytes to transfer */, 
+               int blocks       /* sector count */, 
+               BOOL islast      /* last write for track */)
 {
 	return (write_xg1(scgp, bp, sectaddr, size, blocks));
 }

Modified: nonameyet/branches/cleanup/cdrecord/scsi_cdr_mmc4.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/scsi_cdr_mmc4.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/scsi_cdr_mmc4.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -60,7 +60,7 @@
 #include "scsimmc.h"
 #include "cdrecord.h"
 
-void	print_capabilities_mmc4 __PR((SCSI *scgp));
+void	print_capabilities_mmc4(SCSI *scgp);
 
 #define	DOES(what, flag)	printf("  Does %s%s\n", flag?"":"not ", what)
 

Modified: nonameyet/branches/cleanup/cdrecord/scsi_mmc.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/scsi_mmc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/scsi_mmc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -66,14 +66,16 @@
 
 
 
-int	get_configuration	__PR((SCSI *scgp, caddr_t bp, int cnt, int st_feature, int rt));
-static	int	get_conflen		__PR((SCSI *scgp, int st_feature, int rt));
-int	get_curprofile		__PR((SCSI *scgp));
-static	int	get_profiles		__PR((SCSI *scgp, caddr_t bp, int cnt));
-int	print_profiles		__PR((SCSI *scgp));
-int	get_proflist		__PR((SCSI *scgp, BOOL *wp, BOOL *cdp, BOOL *dvdp, BOOL *dvdplusp, BOOL *ddcdp));
-int	get_wproflist		__PR((SCSI *scgp, BOOL *cdp, BOOL *dvdp,
-							BOOL *dvdplusp, BOOL *ddcdp));
+int	get_configuration(SCSI *scgp, caddr_t bp, int cnt, int st_feature, 
+								int rt);
+static	int	get_conflen(SCSI *scgp, int st_feature, int rt);
+int	get_curprofile(SCSI *scgp);
+static	int	get_profiles(SCSI *scgp, caddr_t bp, int cnt);
+int	print_profiles(SCSI *scgp);
+int	get_proflist(SCSI *scgp, BOOL *wp, BOOL *cdp, BOOL *dvdp, BOOL *dvdplusp,
+						 BOOL *ddcdp);
+int	get_wproflist(SCSI *scgp, BOOL *cdp, BOOL *dvdp, BOOL *dvdplusp, 
+						  BOOL *ddcdp);
 
 /*
  * Get feature codes

Modified: nonameyet/branches/cleanup/cdrecord/scsi_mmc4.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/scsi_mmc4.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/scsi_mmc4.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -61,7 +61,7 @@
 #include "scsimmc.h"
 #include "cdrecord.h"
 
- int	get_supported_cdrw_media_types	__PR((SCSI *scgp));
+ int	get_supported_cdrw_media_types(SCSI *scgp);
 
 /*
  * Retrieve list of supported cd-rw media types (feature 0x37)

Modified: nonameyet/branches/cleanup/cdrecord/scsi_scan.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/scsi_scan.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/scsi_scan.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -53,9 +53,9 @@
 #include "scsi_scan.h"
 #include "cdrecord.h"
 
-static	void	print_product		__PR((FILE *f, struct scsi_inquiry *ip));
-int	select_target		__PR((SCSI *scgp, FILE *f));
-static	int	select_unit		__PR((SCSI *scgp, FILE *f));
+static	void	print_product(FILE *f, struct scsi_inquiry *ip);
+int	select_target(SCSI *scgp, FILE *f);
+static	int	select_unit(SCSI *scgp, FILE *f);
 
 static void
 print_product(FILE *f, struct  scsi_inquiry *ip)

Modified: nonameyet/branches/cleanup/cdrecord/scsi_scan.h
===================================================================
--- nonameyet/branches/cleanup/cdrecord/scsi_scan.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/scsi_scan.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -34,6 +34,6 @@
 #ifndef	_SCSI_SCAN_H
 #define	_SCSI_SCAN_H
 
-extern	int	select_target		__PR((SCSI *scgp, FILE *f));
+extern	int	select_target(SCSI *scgp, FILE *f);
 
 #endif	/* _SCSI_SCAN_H */

Modified: nonameyet/branches/cleanup/cdrecord/sector.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/sector.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/sector.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -58,11 +58,11 @@
 #define	HAVE_NEW_LIB_EDC
 #endif
 
-int	encspeed	__PR((BOOL be_verbose));
-void	encsectors	__PR((track_t *trackp, Uchar *bp, int address, int nsecs));
-void	scrsectors	__PR((track_t *trackp, Uchar *bp, int address, int nsecs));
-void	encodesector	__PR((Uchar *sp, int sectype, int address));
-void	fillsector	__PR((Uchar *sp, int sectype, int address));
+int	encspeed(BOOL be_verbose);
+void	encsectors(track_t *trackp, Uchar *bp, int address, int nsecs);
+void	scrsectors(track_t *trackp, Uchar *bp, int address, int nsecs);
+void	encodesector(Uchar *sp, int sectype, int address);
+void	fillsector(Uchar *sp, int sectype, int address);
 
 /*
  * Sector types known by lib libedc_ecc:

Modified: nonameyet/branches/cleanup/cdrecord/subchan.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/subchan.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/subchan.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -47,26 +47,27 @@
 #include "cdrecord.h"
 #include "crc16.h"
 
-int	do_leadin	__PR((track_t *trackp));
-int	write_leadin	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp, int leadinstart));
-int	write_leadout	__PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
-void	fillsubch	__PR((track_t *trackp, Uchar *sp, int secno, int nsecs));
-void	filltpoint	__PR((Uchar *sub, int ctrl_adr, int point, msf_t *mp));
-void	fillttime	__PR((Uchar *sub, msf_t *mp));
-static	void	filldsubq	__PR((Uchar *sub, int ca, int t, int i, msf_t *mrp, msf_t *mp));
-static	void	fillmcn		__PR((Uchar *sub, Uchar *mcn));
-static	void	fillisrc	__PR((Uchar *sub, Uchar *isrc));
-static	int	ascii2q		__PR((int c));
-static	void	qpto16		__PR((Uchar *sub, Uchar *subq, int dop));
-void	qpto96		__PR((Uchar *sub, Uchar *subq, int dop));
-void	addrw		__PR((Uchar *sub, Uchar	*subrwptr));
-void	qwto16		__PR((Uchar *subq, Uchar *subptr));
-void	subrecodesecs	__PR((track_t *trackp, Uchar *bp, int address, int nsecs));
-static	void	subinterleave	__PR((Uchar *sub));
+int	do_leadin(track_t *trackp);
+int	write_leadin(SCSI *scgp, cdr_t *dp, track_t *trackp, int leadinstart);
+int	write_leadout(SCSI *scgp, cdr_t *dp, track_t *trackp);
+void	fillsubch(track_t *trackp, Uchar *sp, int secno, int nsecs);
+void	filltpoint(Uchar *sub, int ctrl_adr, int point, msf_t *mp);
+void	fillttime(Uchar *sub, msf_t *mp);
+static	void	filldsubq(Uchar *sub, int ca, int t, int i, msf_t *mrp, 
+								 msf_t *mp);
+static	void	fillmcn(Uchar *sub, Uchar *mcn);
+static	void	fillisrc(Uchar *sub, Uchar *isrc);
+static	int	ascii2q(int c);
+static	void	qpto16(Uchar *sub, Uchar *subq, int dop);
+void	qpto96(Uchar *sub, Uchar *subq, int dop);
+void	addrw(Uchar *sub, Uchar	*subrwptr);
+void	qwto16(Uchar *subq, Uchar *subptr);
+void	subrecodesecs(track_t *trackp, Uchar *bp, int address, int nsecs);
+static	void	subinterleave(Uchar *sub);
 
 /*#define	TEST_CRC*/
 #ifdef	TEST_CRC
-static	void	testcrc		__PR((void));
+static	void	testcrc(void);
 #endif
 
 /*Die 96 Bits == 12 Bytes haben folgendes Aussehen:*/
@@ -909,7 +910,7 @@
 
 */
 
-static	int	b	__PR((int bcd));
+static	int	b(int bcd);
 
 
 static int

Modified: nonameyet/branches/cleanup/cdrecord/wm_packet.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/wm_packet.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/wm_packet.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -55,7 +55,7 @@
 
 extern	char	*buf;			/* The transfer buffer */
 
-int	write_packet_data __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
+int	write_packet_data(SCSI *scgp, cdr_t *dp, track_t *trackp);
 
 int
 write_packet_data(SCSI *scgp, cdr_t *dp, track_t *trackp)

Modified: nonameyet/branches/cleanup/cdrecord/wm_session.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/wm_session.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/wm_session.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -52,4 +52,4 @@
 
 extern	char	*buf;			/* The transfer buffer */
 
-int	write_session_data __PR((SCSI *scgp, cdr_t *dp, track_t *trackp));
+int	write_session_data(SCSI *scgp, cdr_t *dp, track_t *trackp);

Modified: nonameyet/branches/cleanup/cdrecord/wm_track.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/wm_track.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/wm_track.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -51,4 +51,4 @@
 
 extern	char	*buf;			/* The transfer buffer */
 
-int	write_track_data __PR((cdr_t *dp, int track, track_t *trackp));
+int	write_track_data(cdr_t *dp, int track, track_t *trackp);

Modified: nonameyet/branches/cleanup/cdrecord/xio.c
===================================================================
--- nonameyet/branches/cleanup/cdrecord/xio.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/xio.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -62,9 +62,9 @@
 static xio_t	**x_tail = NULL;
 
 
-static	xio_t	*xnewnode	__PR((char *name));
-void	*xopen		__PR((char *name, int oflag, int mode));
-int	xclose		__PR((void *vp));
+static	xio_t	*xnewnode(char *name);
+void	*xopen(char *name, int oflag, int mode);
+int	xclose(void *vp);
 
 static xio_t *
 xnewnode(char *name)

Modified: nonameyet/branches/cleanup/cdrecord/xio.h
===================================================================
--- nonameyet/branches/cleanup/cdrecord/xio.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/cdrecord/xio.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -48,7 +48,7 @@
 
 #define	xfileno(p)	(((xio_t *)(p))->x_file)
 
-extern	void	*xopen		__PR((char *name, int oflag, int mode));
-extern	int	xclose		__PR((void *vp));
+extern	void	*xopen(char *name, int oflag, int mode);
+extern	int	xclose(void *vp);
 
 #endif

Modified: nonameyet/branches/cleanup/include/device.h
===================================================================
--- nonameyet/branches/cleanup/include/device.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/device.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -143,14 +143,14 @@
 #define	_dev_make(mbits, majo, mino)	((((XDEV_T)(majo)) << (mbits) | \
 							((XDEV_T)(mino)))
 
-extern	void	dev_init	__PR((BOOL debug));
+extern	void	dev_init(BOOL debug);
 #ifndef	dev_major
-extern	XDEV_T	dev_major	__PR((XDEV_T dev));
-extern	XDEV_T	_dev_major	__PR((int mbits, XDEV_T dev));
-extern	XDEV_T	dev_minor	__PR((XDEV_T dev));
-extern	XDEV_T	_dev_minor	__PR((int mbits, XDEV_T dev));
-extern	XDEV_T	dev_make	__PR((XDEV_T majo, XDEV_T mino));
-extern	XDEV_T	_dev_make	__PR((int mbits, XDEV_T majo, XDEV_T mino));
+extern	XDEV_T	dev_major(XDEV_T dev);
+extern	XDEV_T	_dev_major(int mbits, XDEV_T dev);
+extern	XDEV_T	dev_minor(XDEV_T dev);
+extern	XDEV_T	_dev_minor(int mbits, XDEV_T dev);
+extern	XDEV_T	dev_make(XDEV_T majo, XDEV_T mino);
+extern	XDEV_T	_dev_make(int mbits, XDEV_T majo, XDEV_T mino);
 #endif
 
 #endif	/* __XDEV__ */

Modified: nonameyet/branches/cleanup/include/getargs.h
===================================================================
--- nonameyet/branches/cleanup/include/getargs.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/getargs.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -51,14 +51,14 @@
 #define	BADFMT		(-2)	/* Error in format string	*/
 #define	NOTAFILE	(-3)	/* Seems to be a flag type	*/
 
-typedef	int	(*getargfun)	__PR((const void *, void *));
+typedef	int	(*getargfun)(const void *, void *);
 
 /*
  * Keep in sync with schily.h
  */
-extern	int	getallargs __PR((int *, char * const**, const char *, ...));
-extern	int	getargs __PR((int *, char * const**, const char *, ...));
-extern	int	getfiles __PR((int *, char * const**, const char *));
+extern	int	getallargs(int *, char * const**, const char *, ...);
+extern	int	getargs(int *, char * const**, const char *, ...);
+extern	int	getfiles(int *, char * const**, const char *);
 
 #ifdef	__cplusplus
 }

Modified: nonameyet/branches/cleanup/include/libport.h
===================================================================
--- nonameyet/branches/cleanup/include/libport.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/libport.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -92,27 +92,27 @@
 #endif
 
 #ifndef	HAVE_GETHOSTID
-extern	long		gethostid	__PR((void));
+extern	long		gethostid(void);
 #endif
 #ifndef	HAVE_GETHOSTNAME
-extern	int		gethostname	__PR((char *name, int namelen));
+extern	int		gethostname(char *name, int namelen);
 #endif
 #ifndef	HAVE_GETDOMAINNAME
-extern	int		getdomainname	__PR((char *name, int namelen));
+extern	int		getdomainname(char *name, int namelen);
 #endif
 #ifndef	HAVE_GETPAGESIZE
-EXPORT	int		getpagesize	__PR((void));
+int		getpagesize(void);
 #endif
 #ifndef	HAVE_USLEEP
-extern	int		usleep		__PR((int usec));
+extern	int		usleep(int usec);
 #endif
 
 #if	!defined(HAVE_STRDUP) || defined(__SVR4)
-extern	char		*strdup		__PR((const char *s));
+extern	char		*strdup(const char *s);
 #endif
 
 #ifndef	HAVE_RENAME
-extern	int		rename		__PR((const char *old, const char *new));
+extern	int		rename(const char *old, const char *new);
 #endif
 
 #ifdef	__cplusplus

Modified: nonameyet/branches/cleanup/include/librmt.h
===================================================================
--- nonameyet/branches/cleanup/include/librmt.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/librmt.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -51,25 +51,25 @@
 /*
  * remote.c
  */
-extern	void		rmtinit		__PR((int (*errmsgn)(int, const char *, ...),
-						void (*eexit)(int)));
-extern	int		rmtdebug	__PR((int dlevel));
-extern	char		*rmtfilename	__PR((char *name));
-extern	char		*rmthostname	__PR((char *hostname, int hnsize, char *rmtspec));
-extern	int		rmtgetconn	__PR((char *host, int trsize, int excode));
-extern	int		rmtopen		__PR((int fd, char *fname, int fmode));
-extern	int		rmtclose	__PR((int fd));
-extern	int		rmtread		__PR((int fd, char *buf, int count));
-extern	int		rmtwrite	__PR((int fd, char *buf, int count));
-extern	off_t		rmtseek		__PR((int fd, off_t offset, int whence));
-extern	int		rmtioctl	__PR((int fd, int cmd, int count));
+extern	void		rmtinit(int (*errmsgn)(int, const char *, ...),
+								  void (*eexit)(int));
+extern	int		rmtdebug(int dlevel);
+extern	char		*rmtfilename(char *name);
+extern	char		*rmthostname(char *hostname, int hnsize, char *rmtspec);
+extern	int		rmtgetconn(char *host, int trsize, int excode);
+extern	int		rmtopen(int fd, char *fname, int fmode);
+extern	int		rmtclose(int fd);
+extern	int		rmtread(int fd, char *buf, int count);
+extern	int		rmtwrite(int fd, char *buf, int count);
+extern	off_t		rmtseek(int fd, off_t offset, int whence);
+extern	int		rmtioctl(int fd, int cmd, int count);
 #ifdef	MTWEOF
-extern	int		rmtstatus	__PR((int fd, struct mtget *mtp));
+extern	int		rmtstatus(int fd, struct mtget *mtp);
 #endif
-extern	int		rmtxstatus	__PR((int fd, struct rmtget *mtp));
+extern	int		rmtxstatus(int fd, struct rmtget *mtp);
 #ifdef	MTWEOF
-extern	void		_rmtg2mtg	__PR((struct mtget *mtp, struct rmtget *rmtp));
-extern	int		_mtg2rmtg	__PR((struct rmtget *rmtp, struct mtget *mtp));
+extern	void		_rmtg2mtg(struct mtget *mtp, struct rmtget *rmtp);
+extern	int		_mtg2rmtg(struct rmtget *rmtp, struct mtget *mtp);
 #endif
 
 #endif	/* _LIBRMT_H */

Modified: nonameyet/branches/cleanup/include/patmatch.h
===================================================================
--- nonameyet/branches/cleanup/include/patmatch.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/patmatch.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -94,20 +94,20 @@
 
 #define	MAXPAT	128	/* Maximum length of pattern */
 
-extern	int	    patcompile	__PR((const unsigned char * __pat, int __patlen, int * __aux));
+extern	int patcompile(const unsigned char *__pat, int __patlen, int *__aux);
 
-extern	unsigned char *opatmatch	__PR((const unsigned char * __pat, const int * __aux,
-						const  unsigned char * __str, int __soff, int __slen,
-						int __alt));
-extern	unsigned char *opatlmatch __PR((const unsigned char * __pat, const int * __aux,
-						const  unsigned char * __str, int __soff, int __slen,
-						int __alt));
-extern	unsigned char *patmatch	__PR((const unsigned char * __pat, const int * __aux,
-						const  unsigned char * __str, int __soff, int __slen,
-						int __alt, int __state[]));
-extern	unsigned char *patlmatch __PR((const unsigned char * __pat, const int * __aux,
-						const  unsigned char * __str, int __soff, int __slen,
-						int __alt, int __state[]));
+extern	unsigned char *opatmatch(const unsigned char *__pat, const int *__aux,
+											 const unsigned char *__str, int __soff, 
+											 int __slen, int __alt);
+extern	unsigned char *opatlmatch(const unsigned char *__pat, const int *__aux,
+											  const unsigned char *__str, int __soff, 
+											  int __slen, int __alt);
+extern	unsigned char *patmatch(const unsigned char *__pat, const int *__aux,
+											const unsigned char *__str, int __soff, 
+											int __slen, int __alt, int __state[]);
+extern	unsigned char *patlmatch(const unsigned char *__pat, const int *__aux,
+											 const unsigned char *__str, int __soff, 
+											 int __slen, int __alt, int __state[]);
 
 #ifdef	__cplusplus
 }

Modified: nonameyet/branches/cleanup/include/schily.h
===================================================================
--- nonameyet/branches/cleanup/include/schily.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/schily.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -108,138 +108,131 @@
 #endif
 
 #ifdef	EOF	/* stdio.h has been included */
-extern	int	_cvmod __PR((const char *, int *, int *));
-extern	FILE	*_fcons __PR((FILE *, int, int));
-extern	FILE	*fdup __PR((FILE *));
-extern	int	fdown __PR((FILE *));
-extern	int	fexecl __PR((const char *, FILE *, FILE *, FILE *,
-							const char *, ...));
-extern	int	fexecle __PR((const char *, FILE *, FILE *, FILE *,
-							const char *, ...));
+extern	int	_cvmod(const char *, int *, int *);
+extern	FILE	*_fcons(FILE *, int, int);
+extern	FILE	*fdup(FILE *);
+extern	int	fdown(FILE *);
+extern	int	fexecl(const char *, FILE *, FILE *, FILE *, const char *, ...);
+extern	int	fexecle(const char *, FILE *, FILE *, FILE *, const char *, ...);
 		/* 6th arg not const, fexecv forces av[ac] = NULL */
-extern	int	fexecv __PR((const char *, FILE *, FILE *, FILE *, int,
-							char **));
-extern	int	fexecve __PR((const char *, FILE *, FILE *, FILE *,
-					char * const *, char * const *));
-extern	int	fspawnv __PR((FILE *, FILE *, FILE *, int, char * const *));
-extern	int	fspawnl __PR((FILE *, FILE *, FILE *,
-					const char *, const char *, ...));
-extern	int	fspawnv_nowait __PR((FILE *, FILE *, FILE *,
-					const char *, int, char *const*));
-extern	int	fgetline __PR((FILE *, char *, int));
-extern	int	fgetstr __PR((FILE *, char *, int));
-extern	void	file_raise __PR((FILE *, int));
-extern	int	fileclose __PR((FILE *));
-extern	FILE	*fileluopen __PR((int, const char *));
-extern	FILE	*fileopen __PR((const char *, const char *));
+extern	int	fexecv(const char *, FILE *, FILE *, FILE *, int, char **);
+extern	int	fexecve(const char *, FILE *, FILE *, FILE *, char * const *, 
+							  char * const *);
+extern	int	fspawnv(FILE *, FILE *, FILE *, int, char * const *);
+extern	int	fspawnl(FILE *, FILE *, FILE *, const char *, const char *, ...);
+extern	int	fspawnv_nowait(FILE *, FILE *, FILE *, const char *, int, 
+										char *const*);
+extern	int	fgetline(FILE *, char *, int);
+extern	int	fgetstr(FILE *, char *, int);
+extern	void	file_raise(FILE *, int);
+extern	int	fileclose(FILE *);
+extern	FILE	*fileluopen(int, const char *);
+extern	FILE	*fileopen(const char *, const char *);
 #ifdef	_INCL_SYS_TYPES_H
-extern	FILE	*filemopen __PR((const char *, const char *, mode_t));
+extern	FILE	*filemopen(const char *, const char *, mode_t);
 #endif
 #ifdef	FOUND_OFF_T
-extern	off_t	filepos __PR((FILE *));
+extern	off_t	filepos(FILE *);
 #endif
-extern	int	fileread __PR((FILE *, void *, int));
-extern	int	ffileread __PR((FILE *, void *, int));
-extern	FILE	*filereopen __PR((const char *, const char *, FILE *));
+extern	int	fileread(FILE *, void *, int);
+extern	int	ffileread(FILE *, void *, int);
+extern	FILE	*filereopen(const char *, const char *, FILE *);
 #ifdef	FOUND_OFF_T
-extern	int	fileseek __PR((FILE *, off_t));
-extern	off_t	filesize __PR((FILE *));
+extern	int	fileseek(FILE *, off_t);
+extern	off_t	filesize(FILE *);
 #endif
 #ifdef	S_IFMT
-extern	int	filestat __PR((FILE *, struct stat *));
+extern	int	filestat(FILE *, struct stat *);
 #endif
-extern	int	filewrite __PR((FILE *, void *, int));
-extern	int	ffilewrite __PR((FILE *, void *, int));
-extern	int	flush __PR((void));
-extern	int	fpipe __PR((FILE **));
+extern	int	filewrite(FILE *, void *, int);
+extern	int	ffilewrite(FILE *, void *, int);
+extern	int	flush(void);
+extern	int	fpipe(FILE **);
 /*extern	int	fprintf __PR((FILE *, const char *, ...)) __printflike__(2, 3);*/
-extern	int	getbroken __PR((FILE *, char *, char, char **, int));
-extern	int	ofindline __PR((FILE *, char, const char *, int,
-							char **, int));
-extern	int	peekc __PR((FILE *));
+extern	int	getbroken(FILE *, char *, char, char **, int);
+extern	int	ofindline(FILE *, char, const char *, int, char **, int);
+extern	int	peekc(FILE *);
 
 #ifdef	__never_def__
 /*
  * We cannot define this or we may get into problems with DOS based systems.
  */
-extern	int	spawnv __PR((FILE *, FILE *, FILE *, int, char * const *));
-extern	int	spawnl __PR((FILE *, FILE *, FILE *,
-					const char *, const char *, ...));
-extern	int	spawnv_nowait __PR((FILE *, FILE *, FILE *,
-					const char *, int, char *const*));
+extern	int	spawnv(FILE *, FILE *, FILE *, int, char * const *);
+extern	int	spawnl(FILE *, FILE *, FILE *, const char *, const char *, ...);
+extern	int	spawnv_nowait(FILE *, FILE *, FILE *, const char *, int, 
+									  char *const*);
 #endif	/* __never_def__m */
 #endif	/* EOF */
 
-extern	int	_niread __PR((int, void *, int));
-extern	int	_niwrite __PR((int, void *, int));
-extern	int	_nixread __PR((int, void *, int));
-extern	int	_nixwrite __PR((int, void *, int));
-extern	int	_openfd __PR((const char *, int));
-extern	int	on_comerr __PR((void (*fun)(int, void *), void *arg));
+extern	int	_niread(int, void *, int);
+extern	int	_niwrite(int, void *, int);
+extern	int	_nixread(int, void *, int);
+extern	int	_nixwrite(int, void *, int);
+extern	int	_openfd(const char *, int);
+extern	int	on_comerr(void (*fun)(int, void *), void *arg);
 /*PRINTFLIKE1*/
-extern	void	comerr __PR((const char *, ...)) __printflike__(1, 2);
+extern	void	comerr(const char *, ...) __printflike__(1, 2);
 /*PRINTFLIKE2*/
-extern	void	comerrno __PR((int, const char *, ...)) __printflike__(2, 3);
+extern	void	comerrno(int, const char *, ...) __printflike__(2, 3);
 /*PRINTFLIKE1*/
-extern	int	errmsg __PR((const char *, ...)) __printflike__(1, 2);
+extern	int	errmsg(const char *, ...) __printflike__(1, 2);
 /*PRINTFLIKE2*/
-extern	int	errmsgno __PR((int, const char *, ...)) __printflike__(2, 3);
+extern	int	errmsgno(int, const char *, ...) __printflike__(2, 3);
 #ifdef	FOUND_SIZE_T
 /*PRINTFLIKE3*/
-extern	int	serrmsg __PR((char *, size_t, const char *, ...)) __printflike__(3, 4);
+extern	int	serrmsg(char *, size_t, const char *, ...) __printflike__(3, 4);
 /*PRINTFLIKE4*/
-extern	int	serrmsgno __PR((int, char *, size_t, const char *, ...)) __printflike__(4, 5);
+extern	int	serrmsgno(int, char *, size_t, const char *, ...) __printflike__(4, 5);
 #endif
-extern	void	comexit	__PR((int));
-extern	char	*errmsgstr __PR((int));
+extern	void	comexit(int);
+extern	char	*errmsgstr(int);
 /*PRINTFLIKE1*/
-extern	int	error __PR((const char *, ...)) __printflike__(1, 2);
-extern	char	*fillbytes __PR((void *, int, char));
-extern	char	*findbytes __PR((const void *, int, char));
-extern	int	findline __PR((const char *, char, const char *,
-							int, char **, int));
-extern	int	getline __PR((char *, int));
-extern	int	getstr __PR((char *, int));
-extern	int	breakline __PR((char *, char, char **, int));
-extern	int	getallargs __PR((int *, char * const**, const char *, ...));
-extern	int	getargs __PR((int *, char * const**, const char *, ...));
-extern	int	getfiles __PR((int *, char * const**, const char *));
-extern	char	*astoi __PR((const char *, int *));
-extern	char	*astol __PR((const char *, long *));
-extern	char	*astolb __PR((const char *, long *, int base));
+extern	int	error(const char *, ...) __printflike__(1, 2);
+extern	char	*fillbytes(void *, int, char);
+extern	char	*findbytes(const void *, int, char);
+extern	int	findline(const char *, char, const char *, int, char **, int);
+extern	int	getline(char *, int);
+extern	int	getstr(char *, int);
+extern	int	breakline(char *, char, char **, int);
+extern	int	getallargs(int *, char * const**, const char *, ...);
+extern	int	getargs(int *, char * const**, const char *, ...);
+extern	int	getfiles(int *, char * const**, const char *);
+extern	char	*astoi(const char *, int *);
+extern	char	*astol(const char *, long *);
+extern	char	*astolb(const char *, long *, int base);
 #ifdef	_UTYPES_H
-extern	char	*astoll __PR((const char *, Llong *));
-extern	char	*astollb __PR((const char *, Llong *, int));
-extern	char	*astoull __PR((const char *, Ullong *));
-extern	char	*astoullb __PR((const char *, Ullong *, int));
+extern	char	*astoll(const char *, Llong *);
+extern	char	*astollb(const char *, Llong *, int);
+extern	char	*astoull(const char *, Ullong *);
+extern	char	*astoullb(const char *, Ullong *, int);
 #endif
 
 /*extern	void	handlecond __PR((const char *, SIGBLK *, int(*)(const char *, long, long), long));*/
 /*extern	void	unhandlecond __PR((SIGBLK *));*/
 
-extern	int		patcompile __PR((const unsigned char *, int, int *));
-extern	unsigned char	*patmatch __PR((const unsigned char *, const int *,
-					const unsigned char *, int, int, int, int[]));
-extern	unsigned char	*patlmatch __PR((const unsigned char *, const int *,
-					const unsigned char *, int, int, int, int[]));
+extern	int		patcompile(const unsigned char *, int, int *);
+extern	unsigned char	*patmatch(const unsigned char *, const int *,
+											 const unsigned char *, int, int, int, int[]);
+extern	unsigned char	*patlmatch(const unsigned char *, const int *,
+											  const unsigned char *, int, int, int, int[]);
 
 /*extern	int	printf __PR((const char *, ...)) __printflike__(1, 2);*/
-extern	char	*movebytes __PR((const void *, void *, int));
+extern	char	*movebytes(const void *, void *, int);
 
-extern	void	save_args __PR((int, char **));
-extern	int	saved_ac __PR((void));
-extern	char	**saved_av __PR((void));
-extern	char	*saved_av0 __PR((void));
+extern	void	save_args(int, char **);
+extern	int	saved_ac(void);
+extern	char	**saved_av(void);
+extern	char	*saved_av0(void);
 #ifndef	seterrno
-extern	int	seterrno __PR((int));
+extern	int	seterrno(int);
 #endif
-extern	void	set_progname __PR((const char *));
-extern	char	*get_progname __PR((void));
+extern	void	set_progname(const char *);
+extern	char	*get_progname(void);
 
-extern	void	setfp __PR((void * const *));
-extern	int	wait_chld __PR((int));		/* for fspawnv_nowait() */
-extern	int	geterrno __PR((void));
-extern	void	raisecond __PR((const char *, long));
+extern	void	setfp(void * const *);
+extern	int	wait_chld(int);		/* for fspawnv_nowait() */
+extern	int	geterrno(void);
+extern	void	raisecond(const char *, long);
 #ifdef	FOUND_SIZE_T
 /*
  * We currently cannot define this here because there IXIX has a definition
@@ -247,64 +240,64 @@
  */
 #ifndef	HAVE_SNPRINTF
 /*PRINTFLIKE3*/
-extern	int	snprintf __PR((char *, size_t, const char *, ...)) __printflike__(3, 4);
+extern	int	snprintf(char *, size_t, const char *, ...) __printflike__(3, 4);
 #endif
 #endif
 /*extern	int	sprintf __PR((char *, const char *, ...)); ist woanders falsch deklariert !!!*/
-extern	char	*strcatl __PR((char *, ...));
-extern	int	streql __PR((const char *, const char *));
+extern	char	*strcatl(char *, ...);
+extern	int	streql(const char *, const char *);
 #ifdef	va_arg
-extern	int	format __PR((void (*)(char, long), long, const char *, va_list));
+extern	int	format(void (*)(char, long), long, const char *, va_list);
 #else
-extern	int	format __PR((void (*)(char, long), long, const char *, void *));
+extern	int	format(void (*)(char, long), long, const char *, void *);
 #endif
 
-extern	int	ftoes __PR((char *, double, int, int));
-extern	int	ftofs __PR((char *, double, int, int));
+extern	int	ftoes(char *, double, int, int);
+extern	int	ftofs(char *, double, int, int);
 
 #ifdef	EOF	/* stdio.h has been included */
 /*PRINTFLIKE2*/
-extern	int	js_fprintf	__PR((FILE *, const char *, ...)) __printflike__(2, 3);
+extern	int	js_fprintf(FILE *, const char *, ...) __printflike__(2, 3);
 /*PRINTFLIKE1*/
-extern	int	js_printf	__PR((const char *, ...)) __printflike__(1, 2);
+extern	int	js_printf(const char *, ...) __printflike__(1, 2);
 #ifdef	FOUND_SIZE_T
 /*PRINTFLIKE3*/
-extern	int	js_snprintf	__PR((char *, size_t, const char *, ...)) __printflike__(3, 4);
+extern	int	js_snprintf(char *, size_t, const char *, ...) __printflike__(3, 4);
 #endif
 /*PRINTFLIKE2*/
-extern	int	js_sprintf	__PR((char *, const char *, ...)) __printflike__(2, 3);
+extern	int	js_sprintf(char *, const char *, ...) __printflike__(2, 3);
 #endif	/* EOF */
 
-extern	void	swabbytes	__PR((void *, int));
-extern	char	**getmainfp	__PR((void));
-extern	char	**getavp	__PR((void));
-extern	char	*getav0		__PR((void));
-extern	void	**getfp		__PR((void));
-extern	int	flush_reg_windows __PR((int));
-extern	int	cmpbytes	__PR((const void *, const void *, int));
-extern	int	cmpnullbytes	__PR((const void *, int));
+extern	void	swabbytes(void *, int);
+extern	char	**getmainfp(void);
+extern	char	**getavp(void);
+extern	char	*getav0(void);
+extern	void	**getfp(void);
+extern	int	flush_reg_windows(int);
+extern	int	cmpbytes(const void *, const void *, int);
+extern	int	cmpnullbytes(const void *, int);
 
 #ifdef	nonono
 #if	defined(HAVE_LARGEFILES)
 /*
  * To allow this, we need to figure out how to do autoconfiguration for off64_t
  */
-extern	FILE	*_fcons64	__PR((FILE *, int, int));
-extern	FILE	*fdup64		__PR((FILE *));
-extern	FILE	*fileluopen64	__PR((int, const char *));
-extern	FILE	*fileopen64	__PR((const char *, const char *));
+extern	FILE	*_fcons64(FILE *, int, int);
+extern	FILE	*fdup64(FILE *);
+extern	FILE	*fileluopen64(int, const char *);
+extern	FILE	*fileopen64(const char *, const char *);
 #ifdef	FOUND_OFF_T
-extern	off64_t	filepos64	__PR((FILE *));
+extern	off64_t	filepos64(FILE *);
 #endif
-extern	FILE	*filereopen64	__PR((const char *, const char *, FILE *));
+extern	FILE	*filereopen64(const char *, const char *, FILE *);
 #ifdef	FOUND_OFF_T
-extern	int	fileseek64	__PR((FILE *, off64_t));
-extern	off64_t	filesize64	__PR((FILE *));
+extern	int	fileseek64(FILE *, off64_t);
+extern	off64_t	filesize64(FILE *);
 #endif
 #ifdef	S_IFMT
-extern	int	filestat64	__PR((FILE *, struct stat *));
+extern	int	filestat64(FILE *, struct stat *);
 #endif
-extern	int	_openfd64	__PR((const char *, int));
+extern	int	_openfd64(const char *, int);
 #endif
 #endif
 

Modified: nonameyet/branches/cleanup/include/sigblk.h
===================================================================
--- nonameyet/branches/cleanup/include/sigblk.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/sigblk.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -52,7 +52,7 @@
 	const char	*sb_signame;	/* Name of software signal	*/
 
 					/* sb_sigfun: function to call	*/
-	int		(*sb_sigfun)	__PR((const char *, long, long));
+	int		(*sb_sigfun)(const char *, long, long);
 
 	long		sb_sigarg;	/* Second arg for sb_sigfun	*/
 } SIGBLK;
@@ -64,14 +64,14 @@
  *	2)	The argument from the handlecond() call
  *	3)	The argument from the raisecond() call
  */
-typedef	int	(*handlefunc_t)		__PR((const char *, long, long));
+typedef	int	(*handlefunc_t)(const char *, long, long);
 
-extern	void	handlecond		__PR((const char *, SIGBLK *,
-					    int(*)(const char *, long, long),
-									long));
-extern	void	raisecond		__PR((const char *, long));
-extern	void	starthandlecond		__PR((SIGBLK *));
-extern	void	unhandlecond		__PR((SIGBLK *));
+extern	void	handlecond(const char *, SIGBLK *,
+					    		  int(*)(const char *, long, long),
+								  long);
+extern	void	raisecond(const char *, long);
+extern	void	starthandlecond(SIGBLK *);
+extern	void	unhandlecond(SIGBLK *);
 
 #ifdef	__cplusplus
 }

Modified: nonameyet/branches/cleanup/include/strdefs.h
===================================================================
--- nonameyet/branches/cleanup/include/strdefs.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/strdefs.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -74,44 +74,44 @@
 #define	NULL	0
 #endif
 
-extern void *memcpy	__PR((void *, const void *, int));
-extern void *memmove	__PR((void *, const void *, int));
-extern char *strcpy	__PR((char *, const char *));
-extern char *strncpy	__PR((char *, const char *, int));
+extern void *memcpy(void *, const void *, int);
+extern void *memmove(void *, const void *, int);
+extern char *strcpy(char *, const char *);
+extern char *strncpy(char *, const char *, int);
 
-extern char *strcat	__PR((char *, const char *));
-extern char *strncat	__PR((char *, const char *, int));
+extern char *strcat(char *, const char *);
+extern char *strncat(char *, const char *, int);
 
-extern int memcmp	__PR((const void *, const void *, int));
-extern int strcmp	__PR((const char *, const char *));
-extern int strcoll	__PR((const char *, const char *));
-extern int strncmp	__PR((const char *, const char *, int));
-extern int strxfrm	__PR((char *, const char *, int));
+extern int memcmp(const void *, const void *, int);
+extern int strcmp(const char *, const char *);
+extern int strcoll(const char *, const char *);
+extern int strncmp(const char *, const char *, int);
+extern int strxfrm(char *, const char *, int);
 
-extern void *memchr	__PR((const void *, int, int));
-extern char *strchr	__PR((const char *, int));
+extern void *memchr(const void *, int, int);
+extern char *strchr(const char *, int);
 
-extern int strcspn	__PR((const char *, const char *));
+extern int strcspn(const char *, const char *);
 /*#pragma int_to_unsigned strcspn*/
 
-extern char *strpbrk	__PR((const char *, const char *));
-extern char *strrchr	__PR((const char *, int));
+extern char *strpbrk(const char *, const char *);
+extern char *strrchr(const char *, int);
 
-extern int strspn	__PR((const char *, const char *));
+extern int strspn(const char *, const char *);
 /*#pragma int_to_unsigned strspn*/
 
-extern char *strstr	__PR((const char *, const char *));
-extern char *strtok	__PR((char *, const char *));
-extern void *memset	__PR((void *, int, int));
-extern char *strerror	__PR((int));
+extern char *strstr(const char *, const char *);
+extern char *strtok(char *, const char *);
+extern void *memset(void *, int, int);
+extern char *strerror(int);
 
-extern int strlen	__PR((const char *));
+extern int strlen(const char *);
 /*#pragma int_to_unsigned strlen*/
 
-extern void *memccpy	__PR((void *, const void *, int, int));
+extern void *memccpy(void *, const void *, int, int);
 
-extern int strcasecmp	__PR((const char *, const char *));
-extern int strncasecmp	__PR((const char *, const char *, int));
+extern int strcasecmp(const char *, const char *);
+extern int strncasecmp(const char *, const char *, int);
 
 /*#define	index	strchr*/
 /*#define	rindex	strrchr*/

Modified: nonameyet/branches/cleanup/include/termcap.h
===================================================================
--- nonameyet/branches/cleanup/include/termcap.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/termcap.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -55,16 +55,16 @@
 extern	char	*UP;		/* Cursor up string from "up" capability */
 extern	short	ospeed;		/* output speed coded as in ioctl */
 
-extern	int	tgetent		__PR((char *bp, char *name));
-extern	int	tcsetflags	__PR((int flags));
-extern	char	*tcgetbuf	__PR((void));
-extern	int	tgetnum		__PR((char *ent));
-extern	BOOL	tgetflag	__PR((char *ent));
-extern	char	*tgetstr		__PR((char *ent, char **array));
-extern	char	*tdecode		__PR((char *ep, char **array));
+extern	int	tgetent(char *bp, char *name);
+extern	int	tcsetflags(int flags);
+extern	char	*tcgetbuf(void);
+extern	int	tgetnum(char *ent);
+extern	BOOL	tgetflag(char *ent);
+extern	char	*tgetstr(char *ent, char **array);
+extern	char	*tdecode(char *ep, char **array);
 
-extern	int	tputs		__PR((char *cp, int affcnt, int (*outc)(int c)));
-extern	char	*tgoto		__PR((char *cm, int destcol, int destline));
+extern	int	tputs(char *cp, int affcnt, int (*outc)(int c));
+extern	char	*tgoto(char *cm, int destcol, int destline);
 
 #ifdef	__cplusplus
 }

Modified: nonameyet/branches/cleanup/include/unixstd.h
===================================================================
--- nonameyet/branches/cleanup/include/unixstd.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/unixstd.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -118,15 +118,15 @@
  * Maybe we need a lot more definitions here...
  * It is not clear whether we should have prototyped definitions.
  */
-extern	int	access	__PR((const char *, int));
-extern	int	close	__PR((int));
-extern	int	dup	__PR((int));
-extern	int	dup2	__PR((int, int));
-extern	void	_exit	__PR((int));
-extern	int	link	__PR((const char *, const char *));
-extern	int	read	__PR((int, void *, size_t));
-extern	int	unlink	__PR((const char *));
-extern	int	write	__PR((int, void *, size_t));
+extern	int	access(const char *, int);
+extern	int	close(int);
+extern	int	dup(int);
+extern	int	dup2(int, int);
+extern	void	_exit(int);
+extern	int	link(const char *, const char *);
+extern	int	read(int, void *, size_t);
+extern	int	unlink(const char *);
+extern	int	write(int, void *, size_t);
 #endif
 
 #endif	/* _UNIXSTD_H */

Modified: nonameyet/branches/cleanup/include/unls.h
===================================================================
--- nonameyet/branches/cleanup/include/unls.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/include/unls.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -64,18 +64,18 @@
 #endif
 };
 
-extern int		init_unls		__PR((void));
-extern int		register_unls		__PR((struct unls_table *));
-extern int		unregister_unls		__PR((struct unls_table *));
-extern struct unls_table *find_unls		__PR((char *));
-extern void		list_unls		__PR((void));
-extern struct unls_table *load_unls		__PR((char *));
-extern void 		unload_unls		__PR((struct unls_table *));
-extern struct unls_table *load_unls_default	__PR((void));
-extern int		init_unls_file		__PR((char * name));
+extern int		init_unls(void);
+extern int		register_unls(struct unls_table *);
+extern int		unregister_unls(struct unls_table *);
+extern struct unls_table *find_unls(char *);
+extern void		list_unls(void);
+extern struct unls_table *load_unls(char *);
+extern void 		unload_unls(struct unls_table *);
+extern struct unls_table *load_unls_default(void);
+extern int		init_unls_file(char * name);
 
 #ifdef USE_ICONV
-extern int             init_nls_iconv          __PR((char * name));
+extern int             init_nls_iconv(char * name);
 #endif
 
 #ifdef	__cplusplus

Modified: nonameyet/branches/cleanup/libedc/ecc.h
===================================================================
--- nonameyet/branches/cleanup/libedc/ecc.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libedc/ecc.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -50,9 +50,9 @@
    On input: 2352 bytes of audio data is given.
    On output: 3136 bytes of CIRC enriched audio data are returned.
  */
-int do_encode_L1 __PR((unsigned char in[L1_RAW*FRAMES_PER_SECTOR],
-		unsigned char out[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
-		int delay1, int delay2, int delay3, int scramble));
+int do_encode_L1(unsigned char in[L1_RAW*FRAMES_PER_SECTOR],
+					  unsigned char out[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
+					  int delay1, int delay2, int delay3, int scramble);
 
 /* data sector definitions for RSPC */
 /* user data bytes per frame */
@@ -69,9 +69,9 @@
 #define MODE_2_FORM_2	4
 
 /* set one of the MODE_* constants for subsequent data sector formatting */
-int set_sector_type	__PR((int st));
+int set_sector_type(int st);
 /* get the current sector type setting for data sector formatting */
-int get_sector_type	__PR((void));
+int get_sector_type(void);
 
 /* data sector layer 2 Reed-Solomon Product Code encoder */
 /* encode the given data portion depending on sector type (see
@@ -95,15 +95,15 @@
                     in the inout array.
                     Sync-, header- and edc- fields will be added.
 */
-int do_encode_L2	__PR((unsigned char *inout, int sectortype, unsigned address));
-int decode_L2_Q		__PR((unsigned char inout[4 + L2_RAW + 12 + L2_Q]));
-int decode_L2_P		__PR((unsigned char inout[4 + L2_RAW + 12 + L2_Q + L2_P]));
-unsigned int build_edc	__PR((unsigned char inout[], int from, int upto));
+int do_encode_L2(unsigned char *inout, int sectortype, unsigned address);
+int decode_L2_Q(unsigned char inout[4 + L2_RAW + 12 + L2_Q]);
+int decode_L2_P(unsigned char inout[4 + L2_RAW + 12 + L2_Q + L2_P]);
+unsigned int build_edc(unsigned char inout[], int from, int upto);
 
 /* generates f2 frames from otherwise fully formatted sectors (generated by
    do_encode_L2()). */
 #define	EDC_SCRAMBLE_NOSWAP	1	/* Do not swap bytes while scrambling */
-int scramble_L2		__PR((unsigned char *inout));
+int scramble_L2(unsigned char *inout);
 
 /* r-w sub channel definitions */
 #define RS_SUB_RW_BITS 6
@@ -123,12 +123,12 @@
      delay1: use low level delay line
      scramble: perform low level permutations
  */
-int do_encode_sub __PR((unsigned char in[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
+int do_encode_sub(unsigned char in[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
 		unsigned char out[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME],
-		int delay1, int scramble));
-int do_decode_sub __PR((unsigned char in[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME],
-		unsigned char out[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
-		int delay1, int scramble));
+		int delay1, int scramble);
+int do_decode_sub(unsigned char in[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME],
+						unsigned char out[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
+						int delay1, int scramble);
 
-int decode_LSUB_Q	__PR((unsigned char inout[LSUB_QRAW + LSUB_Q]));
-int decode_LSUB_P	__PR((unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P]));
+int decode_LSUB_Q(unsigned char inout[LSUB_QRAW + LSUB_Q]);
+int decode_LSUB_P(unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P]);

Modified: nonameyet/branches/cleanup/libedc/edc_ecc.c
===================================================================
--- nonameyet/branches/cleanup/libedc/edc_ecc.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libedc/edc_ecc.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -54,12 +54,12 @@
 #endif
 
 /* these prototypes will become public when the function are implemented */
-static int do_decode_L2	__PR((unsigned char in[(L2_RAW+L2_Q+L2_P)],
-		unsigned char out[L2_RAW]));
+static int do_decode_L2(unsigned char in[(L2_RAW+L2_Q+L2_P)], 
+								unsigned char out[L2_RAW]);
 
-static int do_decode_L1	__PR((unsigned char in[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
-		unsigned char out[L1_RAW*FRAMES_PER_SECTOR],
-		int delay1, int delay2, int delay3, int scramble));
+static int do_decode_L1(unsigned char in[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
+								unsigned char out[L1_RAW*FRAMES_PER_SECTOR],
+								int delay1, int delay2, int delay3, int scramble);
 
 
 /* ------------- tables generated by gen_encodes --------------*/
@@ -72,7 +72,7 @@
 /*
  * Scrambles 2352 - 12 = 2340 bytes
  */
-int scramble_L2 __PR((unsigned char *inout));
+int scramble_L2(unsigned char *inout);
 
 int scramble_L2(unsigned char *inout)
 {
@@ -113,7 +113,7 @@
 
 #include "l2sq_table"
 
-static int encode_L2_Q	__PR((unsigned char inout[4 + L2_RAW + 4 + 8 + L2_P + L2_Q]));
+static int encode_L2_Q(unsigned char inout[4 + L2_RAW + 4 + 8 + L2_P + L2_Q]);
 
 static int encode_L2_Q(unsigned char inout[4 + L2_RAW + 4 + 8 + L2_P + L2_Q])
 {
@@ -156,7 +156,7 @@
 	return (0);
 }
 
-static int encode_L2_P	__PR((unsigned char inout[4 + L2_RAW + 4 + 8 + L2_P]));
+static int encode_L2_P(unsigned char inout[4 + L2_RAW + 4 + 8 + L2_P]);
 
 static int encode_L2_P(unsigned char inout[4 + L2_RAW + 4 + 8 + L2_P])
 {
@@ -194,14 +194,14 @@
 	return (0);
 }
 
-static unsigned char bin2bcd	__PR((unsigned p));
+static unsigned char bin2bcd(unsigned p);
 
 static unsigned char bin2bcd(unsigned p)
 {
 	return ((p/10)<<4)|(p%10);
 }
 
-static int build_address	__PR((unsigned char inout[], int sectortype, unsigned address));
+static int build_address(unsigned char inout[], int sectortype, unsigned address);
 
 static int 
 build_address(unsigned char inout[], int sectortype, unsigned address)
@@ -229,7 +229,7 @@
 /*
  * Called with 2064, 2056 or 2332 byte difference - all dividable by 4.
  */
-unsigned int build_edc __PR((unsigned char inout[], int from, int upto));
+unsigned int build_edc(unsigned char inout[], int from, int upto);
 
 unsigned int build_edc(unsigned char inout[], int from, int upto)
 {
@@ -248,7 +248,8 @@
 }
 
 /* Layer 2 Product code en/decoder */
-int do_encode_L2 __PR((unsigned char inout[(12 + 4 + L2_RAW+4+8+L2_Q+L2_P)], int sectortype, unsigned address));
+int do_encode_L2(unsigned char inout[(12 + 4 + L2_RAW+4+8+L2_Q+L2_P)], 
+					  int sectortype, unsigned address);
 
 int
 do_encode_L2(unsigned char inout[(12 + 4 + L2_RAW+4+8+L2_Q+L2_P)], 
@@ -319,7 +320,7 @@
 /*--------------------------------------------------------------------------*/
 #include "encoder_tables"
 
-static int encode_L1_Q	__PR((unsigned char inout[L1_RAW + L1_Q]));
+static int encode_L1_Q(unsigned char inout[L1_RAW + L1_Q]);
 
 static int encode_L1_Q(unsigned char inout[L1_RAW + L1_Q])
 {
@@ -347,7 +348,7 @@
 	return (0);
 }
 
-static int encode_L1_P	__PR((unsigned char inout[L1_RAW + L1_Q + L1_P]));
+static int encode_L1_P(unsigned char inout[L1_RAW + L1_Q + L1_P]);
 
 static int encode_L1_P(unsigned char inout[L1_RAW + L1_Q + L1_P])
 {
@@ -373,35 +374,35 @@
 	return (0);
 }
 
-static int decode_L1_Q	__PR((unsigned char inout[L1_RAW + L1_Q]));
+static int decode_L1_Q(unsigned char inout[L1_RAW + L1_Q]);
 
 static int decode_L1_Q(unsigned char inout[L1_RAW + L1_Q])
 {
 	return (0);
 }
 
-static int decode_L1_P	__PR((unsigned char in[L1_RAW + L1_Q + L1_P]));
+static int decode_L1_P(unsigned char in[L1_RAW + L1_Q + L1_P]);
 
 static int decode_L1_P(unsigned char in[L1_RAW + L1_Q + L1_P])
 {
 	return (0);
 }
 
-int decode_L2_Q __PR((unsigned char inout[4 + L2_RAW + 12 + L2_Q]));
+int decode_L2_Q(unsigned char inout[4 + L2_RAW + 12 + L2_Q]);
 
 int decode_L2_Q(unsigned char inout[4 + L2_RAW + 12 + L2_Q])
 {
 	return (0);
 }
 
-int decode_L2_P __PR((unsigned char inout[4 + L2_RAW + 12 + L2_Q + L2_P]));
+int decode_L2_P(unsigned char inout[4 + L2_RAW + 12 + L2_Q + L2_P]);
 
 int decode_L2_P(unsigned char inout[4 + L2_RAW + 12 + L2_Q + L2_P])
 {
 	return (0);
 }
 
-static int encode_LSUB_Q	__PR((unsigned char inout[LSUB_RAW + LSUB_Q]));
+static int encode_LSUB_Q(unsigned char inout[LSUB_RAW + LSUB_Q]);
 
 static int encode_LSUB_Q(unsigned char inout[LSUB_RAW + LSUB_Q])
 {
@@ -428,7 +429,7 @@
 }
 
 
-static int encode_LSUB_P	__PR((unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P]));
+static int encode_LSUB_P(unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P]);
 
 static int encode_LSUB_P(unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P])
 {
@@ -454,7 +455,7 @@
 	return (0);
 }
 
-int decode_LSUB_Q __PR((unsigned char inout[LSUB_QRAW + LSUB_Q]));
+int decode_LSUB_Q(unsigned char inout[LSUB_QRAW + LSUB_Q]);
 
 int decode_LSUB_Q(unsigned char inout[LSUB_QRAW + LSUB_Q])
 {
@@ -476,7 +477,7 @@
 	return (Q[0] != 0 || Q[1] != 0);
 }
 
-int decode_LSUB_P __PR((unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P]));
+int decode_LSUB_P(unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P]);
 
 int decode_LSUB_P(unsigned char inout[LSUB_RAW + LSUB_Q + LSUB_P])
 {
@@ -509,9 +510,9 @@
 static unsigned char l1_delay_line3[MAX_L1_DEL3][L1_RAW+L1_Q+L1_P];
 static unsigned l1_del_index;
 
-int do_encode_L1  __PR((unsigned char in[L1_RAW*FRAMES_PER_SECTOR],
-		unsigned char out[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
-		int delay1, int delay2, int delay3, int permute));
+int do_encode_L1(unsigned char in[L1_RAW*FRAMES_PER_SECTOR],
+					  unsigned char out[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
+					  int delay1, int delay2, int delay3, int permute);
 
 int do_encode_L1(unsigned char in[L1_RAW*FRAMES_PER_SECTOR], 
                  unsigned char out[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR], 
@@ -591,9 +592,9 @@
 }
 
 static
-int do_decode_L1 __PR((unsigned char in[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
-		unsigned char out[L1_RAW*FRAMES_PER_SECTOR],
-		int delay1, int delay2, int delay3, int permute));
+int do_decode_L1(unsigned char in[(L1_RAW+L1_Q+L1_P)*FRAMES_PER_SECTOR],
+					  unsigned char out[L1_RAW*FRAMES_PER_SECTOR],
+					  int delay1, int delay2, int delay3, int permute);
 
 static /* XXX should be non static XXX*/ 
 
@@ -674,8 +675,8 @@
 	return (0);
 }
 
-static int do_decode_L2	__PR((unsigned char in[(L2_RAW+L2_Q+L2_P)],
-		unsigned char out[L2_RAW]));
+static int do_decode_L2(unsigned char in[(L2_RAW+L2_Q+L2_P)],
+								unsigned char out[L2_RAW]);
 
 static int do_decode_L2(unsigned char in[(L2_RAW+L2_Q+L2_P)], 
                         unsigned char out[L2_RAW])
@@ -691,9 +692,9 @@
 
 /* R-W Subchannel en/decoder */
 
-int do_encode_sub __PR((unsigned char in[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
+int do_encode_sub(unsigned char in[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
 		unsigned char out[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME],
-		int delay1, int permute));
+		int delay1, int permute);
 
 int do_encode_sub(unsigned char in[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME], 
                   unsigned char out[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME], 
@@ -740,10 +741,10 @@
 }
 
 int 
-do_decode_sub __PR((
-	unsigned char in[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME],
-	unsigned char out[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
-	int delay1, int permute));
+do_decode_sub(
+		unsigned char in[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME],
+		unsigned char out[LSUB_RAW*PACKETS_PER_SUBCHANNELFRAME],
+		int delay1, int permute);
 
 int 
 do_decode_sub(unsigned char in[(LSUB_RAW+LSUB_Q+LSUB_P)*PACKETS_PER_SUBCHANNELFRAME], 
@@ -794,14 +795,14 @@
 
 static int sectortype = MODE_0;
 
-int get_sector_type __PR((void));
+int get_sector_type(void);
 
 int get_sector_type()
 {
 	return (sectortype);
 }
 
-int set_sector_type __PR((int st));
+int set_sector_type(int st);
 
 int set_sector_type(int st)
 {
@@ -855,8 +856,6 @@
    L1_RAW*FRAMES_PER_SECTOR},
 };
 
-int main	__PR(((int argc, char **argv));
-
 int main(int argc, char *argv[])
 {
 	int encode = 1;

Modified: nonameyet/branches/cleanup/libedc/edcspeed.c
===================================================================
--- nonameyet/branches/cleanup/libedc/edcspeed.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libedc/edcspeed.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -19,7 +19,7 @@
 
 #define	Uchar	unsigned char
 
-static int encspeed __PR((void));
+static int encspeed(void);
 
 static int encspeed()
 {

Modified: nonameyet/branches/cleanup/libhfs_iso/block.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/block.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/block.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -30,8 +30,8 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-int b_readlb		__PR((hfsvol *, unsigned long, block *));
-int b_writelb		__PR((hfsvol *, unsigned long, block *));
+int b_readlb(hfsvol *, unsigned long, block *);
+int b_writelb(hfsvol *, unsigned long, block *);
 
-int b_readab		__PR((hfsvol *, unsigned int, unsigned int, block *));
-int b_writeab		__PR((hfsvol *, unsigned int, unsigned int, block *));
+int b_readab(hfsvol *, unsigned int, unsigned int, block *);
+int b_writeab(hfsvol *, unsigned int, unsigned int, block *);

Modified: nonameyet/branches/cleanup/libhfs_iso/btree.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/btree.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/btree.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -30,18 +30,18 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-int bt_getnode		__PR((node *));
-int bt_putnode		__PR((node *));
+int bt_getnode(node *);
+int bt_putnode(node *);
 
-int bt_readhdr		__PR((btree *));
-int bt_writehdr		__PR((btree *));
+int bt_readhdr(btree *);
+int bt_writehdr(btree *);
 
-int bt_space		__PR((btree *, unsigned int));
+int bt_space(btree *, unsigned int);
 
-int bt_insertx		__PR((node *, unsigned char *, int *));
-int bt_insert		__PR((btree *, unsigned char *, int));
+int bt_insertx(node *, unsigned char *, int *);
+int bt_insert(btree *, unsigned char *, int);
 
-int bt_deletex		__PR((node *, unsigned char *, unsigned char *, int *));
-int bt_delete		__PR((btree *, unsigned char *));
+int bt_deletex(node *, unsigned char *, unsigned char *, int *);
+int bt_delete(btree *, unsigned char *);
 
-int bt_search		__PR((btree *, unsigned char *, node *));
+int bt_search(btree *, unsigned char *, node *);

Modified: nonameyet/branches/cleanup/libhfs_iso/data.c
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/data.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/data.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -56,7 +56,7 @@
 #define MUTDIFF	2082844800L
 #define	TZNONE	0x0FFFFFFFL	/* A timezone diff that cannot occur */
 
-static	void	calctzdiff	__PR((void));
+static	void	calctzdiff(void);
 
 static
 unsigned long tzdiff = TZNONE;

Modified: nonameyet/branches/cleanup/libhfs_iso/data.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/data.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/data.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -30,28 +30,28 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-char d_getb		__PR((unsigned char *));
-short d_getw		__PR((unsigned char *));
-long d_getl		__PR((unsigned char *));
+char d_getb(unsigned char *);
+short d_getw(unsigned char *);
+long d_getl(unsigned char *);
 
-void d_putb		__PR((unsigned char *, char));
-void d_putw		__PR((unsigned char *, short));
-void d_putl		__PR((unsigned char *, long));
+void d_putb(unsigned char *, char);
+void d_putw(unsigned char *, short);
+void d_putl(unsigned char *, long);
 
-void d_fetchb		__PR((unsigned char **, char *));
-void d_fetchw		__PR((unsigned char **, short *));
-void d_fetchl		__PR((unsigned char **, long *));
-void d_fetchs		__PR((unsigned char **, char *, int));
+void d_fetchb(unsigned char **, char *);
+void d_fetchw(unsigned char **, short *);
+void d_fetchl(unsigned char **, long *);
+void d_fetchs(unsigned char **, char *, int);
 
-void d_storeb		__PR((unsigned char **, char));
-void d_storew		__PR((unsigned char **, short));
-void d_storel		__PR((unsigned char **, long));
-void d_stores		__PR((unsigned char **, char *, int));
+void d_storeb(unsigned char **, char);
+void d_storew(unsigned char **, short);
+void d_storel(unsigned char **, long);
+void d_stores(unsigned char **, char *, int);
 
-unsigned long d_tomtime	__PR((unsigned long));
-unsigned long d_toutime	__PR((unsigned long));
+unsigned long d_tomtime(unsigned long);
+unsigned long d_toutime(unsigned long);
 #ifdef APPLE_HYB
-unsigned long d_dtoutime __PR((long));
+unsigned long d_dtoutime(long);
 #endif /* APPLE_HYB */
 
-int d_relstring		__PR((char *, char *));
+int d_relstring(char *, char *);

Modified: nonameyet/branches/cleanup/libhfs_iso/file.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/file.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/file.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -35,15 +35,14 @@
   fkRsrc = 0xff
 };
 
-void f_selectfork	__PR((hfsfile *, int));
-void f_getptrs		__PR((hfsfile *, unsigned long **, unsigned long **, ExtDataRec **));
+void f_selectfork(hfsfile *, int);
+void f_getptrs(hfsfile *, unsigned long **, unsigned long **, ExtDataRec **);
 
-int f_doblock		__PR((hfsfile *, unsigned long, block *,
-	   		   int (*)(hfsvol *, unsigned int, unsigned int, block *)));
+int f_doblock(hfsfile *, unsigned long, block *, 
+				  int (*)(hfsvol *, unsigned int, unsigned int, block *));
 
 # define f_getblock(file, num, bp)	f_doblock(file, num, bp, b_readab)
 # define f_putblock(file, num, bp)	f_doblock(file, num, bp, b_writeab)
 
-int f_alloc		__PR((hfsfile *));
-int f_trunc		__PR((hfsfile *));
-int f_flush		__PR((hfsfile *));
+int f_alloc(hfsfile *);
+int f_flush(hfsfile *);

Modified: nonameyet/branches/cleanup/libhfs_iso/hfs.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/hfs.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/hfs.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -137,66 +137,66 @@
 /*extern unsigned char hfs_charorder[];*/
 
 #ifdef APPLE_HYB
-hfsvol *hfs_mount	__PR((hce_mem *, int, int));
+hfsvol *hfs_mount(hce_mem *, int, int);
 #else
-hfsvol *hfs_mount	__PR((char *, int, int));
+hfsvol *hfs_mount(char *, int, int);
 #endif /* APPLE_HYB */
 
-int hfs_flush		__PR((hfsvol *));
-void hfs_flushall	__PR((void));
+int hfs_flush(hfsvol *);
+void hfs_flushall(void);
 #ifdef APPLE_HYB
-int hfs_umount		__PR((hfsvol *, long, long));
+int hfs_umount(hfsvol *, long, long);
 #else
-int hfs_umount		__PR((hfsvol *));
+int hfs_umount(hfsvol *);
 #endif /* APPLE_HYB */
-void hfs_umountall	__PR((void));
-hfsvol *hfs_getvol	__PR((char *));
-void hfs_setvol		__PR((hfsvol *));
+void hfs_umountall(void);
+hfsvol *hfs_getvol(char *);
+void hfs_setvol(hfsvol *);
 
-int hfs_vstat		__PR((hfsvol *, hfsvolent *));
+int hfs_vstat(hfsvol *, hfsvolent *);
 #ifdef APPLE_HYB
-int hfs_format		__PR((hce_mem *, int, char *));
+int hfs_format(hce_mem *, int, char *);
 #else
-int hfs_format		__PR((char *, int, char *));
+int hfs_format(char *, int, char *);
 #endif /* APPLE_HYB */
 
-int hfs_chdir		__PR((hfsvol *, char *));
-long hfs_getcwd		__PR((hfsvol *));
-int hfs_setcwd		__PR((hfsvol *, long));
-int hfs_dirinfo		__PR((hfsvol *, long *, char *));
+int hfs_chdir(hfsvol *, char *);
+long hfs_getcwd(hfsvol *);
+int hfs_setcwd(hfsvol *, long);
+int hfs_dirinfo(hfsvol *, long *, char *);
 
-hfsdir *hfs_opendir	__PR((hfsvol *, char *));
-int hfs_readdir		__PR((hfsdir *, hfsdirent *));
-int hfs_closedir	__PR((hfsdir *));
+hfsdir *hfs_opendir(hfsvol *, char *);
+int hfs_readdir(hfsdir *, hfsdirent *);
+int hfs_closedir(hfsdir *);
 
-hfsfile *hfs_open	__PR((hfsvol *, char *));
-int hfs_setfork		__PR((hfsfile *, int));
-int hfs_getfork		__PR((hfsfile *));
-long hfs_read		__PR((hfsfile *, void *, unsigned long));
-long hfs_write		__PR((hfsfile *, void *, unsigned long));
-int hfs_truncate	__PR((hfsfile *, unsigned long));
-long hfs_lseek		__PR((hfsfile *, long, int));
+hfsfile *hfs_open(hfsvol *, char *);
+int hfs_setfork(hfsfile *, int);
+int hfs_getfork(hfsfile *);
+long hfs_read(hfsfile *, void *, unsigned long);
+long hfs_write(hfsfile *, void *, unsigned long);
+int hfs_truncate(hfsfile *, unsigned long);
+long hfs_lseek(hfsfile *, long, int);
 #ifdef APPLE_HYB
-int hfs_close		__PR((hfsfile *, long, long));
+int hfs_close(hfsfile *, long, long);
 #else
-int hfs_close		__PR((hfsfile *));
+int hfs_close(hfsfile *);
 #endif /* APPLE_HYB */
 
-int hfs_stat		__PR((hfsvol *, char *, hfsdirent *));
-int hfs_fstat		__PR((hfsfile *, hfsdirent *));
-int hfs_setattr		__PR((hfsvol *, char *, hfsdirent *));
-int hfs_fsetattr	__PR((hfsfile *, hfsdirent *));
+int hfs_stat(hfsvol *, char *, hfsdirent *);
+int hfs_fstat(hfsfile *, hfsdirent *);
+int hfs_setattr(hfsvol *, char *, hfsdirent *);
+int hfs_fsetattr(hfsfile *, hfsdirent *);
 
-int hfs_mkdir		__PR((hfsvol *, char *));
-int hfs_rmdir		__PR((hfsvol *, char *));
+int hfs_mkdir(hfsvol *, char *);
+int hfs_rmdir(hfsvol *, char *);
 
-int hfs_create		__PR((hfsvol *, char *, char *, char *));
-int hfs_delete		__PR((hfsvol *, char *));
+int hfs_create(hfsvol *, char *, char *, char *);
+int hfs_delete(hfsvol *, char *);
 
-int hfs_rename		__PR((hfsvol *, char *, char *));
+int hfs_rename(hfsvol *, char *, char *);
 
 #ifdef APPLE_HYB
-unsigned short hfs_get_drAllocPtr	__PR((hfsfile *));
-int hfs_set_drAllocPtr			__PR((hfsfile *, unsigned short, int size));
-void hfs_vsetbless			__PR((hfsvol *, unsigned long));
+unsigned short hfs_get_drAllocPtr(hfsfile *);
+int hfs_set_drAllocPtr(hfsfile *, unsigned short, int size);
+void hfs_vsetbless(hfsvol *, unsigned long);
 #endif /* APPLE_HYB */

Modified: nonameyet/branches/cleanup/libhfs_iso/internal.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/internal.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/internal.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -326,7 +326,7 @@
   unsigned long mapsz;		/* number of bytes in bitmap */
   int flags;			/* bit flags */
 
-  int (*compare) __PR((unsigned char *, unsigned char *));
+  int (*compare)(unsigned char *, unsigned char *);
 				/* key comparison function */
 } btree;
 

Modified: nonameyet/branches/cleanup/libhfs_iso/low.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/low.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/low.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -99,13 +99,13 @@
   Integer	pmPad[188];	/* reserved */
 } Partition;
 
-int l_lockvol		__PR((hfsvol *));
+int l_lockvol(hfsvol *);
 
-int l_readblock0	__PR((hfsvol *));
-int l_readpm		__PR((hfsvol *));
+int l_readblock0(hfsvol *);
+int l_readpm(hfsvol *);
 
-int l_readmdb		__PR((hfsvol *));
-int l_writemdb		__PR((hfsvol *));
+int l_readmdb(hfsvol *);
+int l_writemdb(hfsvol *);
 
-int l_readvbm		__PR((hfsvol *));
-int l_writevbm		__PR((hfsvol *));
+int l_readvbm(hfsvol *);
+int l_writevbm(hfsvol *);

Modified: nonameyet/branches/cleanup/libhfs_iso/node.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/node.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/node.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -30,19 +30,19 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-void n_init		__PR((node *, btree *, int, int));
+void n_init(node *, btree *, int, int);
 
-int n_new		__PR((node *));
-void n_free		__PR((node *));
+int n_new(node *);
+void n_free(node *);
 
-void n_compact		__PR((node *));
-int n_search		__PR((node *, unsigned char *));
+void n_compact(node *);
+int n_search(node *, unsigned char *);
 
-void n_index		__PR((btree *, unsigned char *, unsigned long, unsigned char *, int *));
-int n_split		__PR((node *, unsigned char *, int *));
+void n_index(btree *, unsigned char *, unsigned long, unsigned char *, int *);
+int n_split(node *, unsigned char *, int *);
 
-void n_insertx		__PR((node *, unsigned char *, int));
-int n_insert		__PR((node *, unsigned char *, int *));
+void n_insertx(node *, unsigned char *, int);
+int n_insert(node *, unsigned char *, int *);
 
-int n_merge		__PR((node *, node *, unsigned char *, int *));
-int n_delete		__PR((node *, unsigned char *, int *));
+int n_merge(node *, node *, unsigned char *, int *);
+int n_delete(node *, unsigned char *, int *);

Modified: nonameyet/branches/cleanup/libhfs_iso/record.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/record.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/record.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -30,23 +30,23 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-void r_packcatkey	__PR((CatKeyRec *, unsigned char *, int *));
-void r_unpackcatkey	__PR((unsigned char *, CatKeyRec *));
+void r_packcatkey(CatKeyRec *, unsigned char *, int *);
+void r_unpackcatkey(unsigned char *, CatKeyRec *);
 
-void r_packextkey	__PR((ExtKeyRec *, unsigned char *, int *));
-void r_unpackextkey	__PR((unsigned char *, ExtKeyRec *));
+void r_packextkey(ExtKeyRec *, unsigned char *, int *);
+void r_unpackextkey(unsigned char *, ExtKeyRec *);
 
-int r_comparecatkeys	__PR((unsigned char *, unsigned char *));
-int r_compareextkeys	__PR((unsigned char *, unsigned char *));
+int r_comparecatkeys(unsigned char *, unsigned char *);
+int r_compareextkeys(unsigned char *, unsigned char *);
 
-void r_packcatdata	__PR((CatDataRec *, unsigned char *, int *));
-void r_unpackcatdata	__PR((unsigned char *, CatDataRec *));
+void r_packcatdata(CatDataRec *, unsigned char *, int *);
+void r_unpackcatdata(unsigned char *, CatDataRec *);
 
-void r_packextdata	__PR((ExtDataRec *, unsigned char *, int *));
-void r_unpackextdata	__PR((unsigned char *, ExtDataRec *));
+void r_packextdata(ExtDataRec *, unsigned char *, int *);
+void r_unpackextdata(unsigned char *, ExtDataRec *);
 
-void r_makecatkey	__PR((CatKeyRec *, long, char *));
-void r_makeextkey	__PR((ExtKeyRec *, int, long, unsigned int));
+void r_makecatkey(CatKeyRec *, long, char *);
+void r_makeextkey(ExtKeyRec *, int, long, unsigned int);
 
-void r_unpackdirent	__PR((long, char *, CatDataRec *, hfsdirent *));
-void r_packdirent	__PR((CatDataRec *, hfsdirent *));
+void r_unpackdirent(long, char *, CatDataRec *, hfsdirent *);
+void r_packdirent(CatDataRec *, hfsdirent *);

Modified: nonameyet/branches/cleanup/libhfs_iso/volume.c
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/volume.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/volume.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -46,7 +46,7 @@
 #include "record.h"
 #include "volume.h"
 
-static	void	markexts	__PR((block *vbm, ExtDataRec *exts));
+static	void	markexts(block *vbm, ExtDataRec *exts);
 
 
 /*

Modified: nonameyet/branches/cleanup/libhfs_iso/volume.h
===================================================================
--- nonameyet/branches/cleanup/libhfs_iso/volume.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libhfs_iso/volume.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -30,29 +30,29 @@
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
-int v_catsearch		__PR((hfsvol *, long, char *, CatDataRec *, char *, node *));
-int v_extsearch		__PR((hfsfile *, unsigned int, ExtDataRec *, node *));
+int v_catsearch(hfsvol *, long, char *, CatDataRec *, char *, node *);
+int v_extsearch(hfsfile *, unsigned int, ExtDataRec *, node *);
 
-int v_getthread		__PR((hfsvol *, long, CatDataRec *, node *, int));
+int v_getthread(hfsvol *, long, CatDataRec *, node *, int);
 
 # define v_getdthread(vol, id, thread, np)  \
     v_getthread(vol, id, thread, np, cdrThdRec)
 # define v_getfthread(vol, id, thread, np)  \
     v_getthread(vol, id, thread, np, cdrFThdRec)
 
-int v_putcatrec		__PR((CatDataRec *, node *));
-int v_putextrec		__PR((ExtDataRec *, node *));
+int v_putcatrec(CatDataRec *, node *);
+int v_putextrec(ExtDataRec *, node *);
 
-int v_allocblocks	__PR((hfsvol *, ExtDescriptor *));
-void v_freeblocks	__PR((hfsvol *, ExtDescriptor *));
+int v_allocblocks(hfsvol *, ExtDescriptor *);
+void v_freeblocks(hfsvol *, ExtDescriptor *);
 
-int v_resolve		__PR((hfsvol **, char *, CatDataRec *, long *, char *, node *));
+int v_resolve(hfsvol **, char *, CatDataRec *, long *, char *, node *);
 
-void v_destruct		__PR((hfsvol *));
-int v_getvol		__PR((hfsvol **));
-int v_flush		__PR((hfsvol *, int));
+void v_destruct(hfsvol *);
+int v_getvol(hfsvol **);
+int v_flush(hfsvol *, int);
 
-int v_adjvalence	__PR((hfsvol *, long, int, int));
-int v_newfolder		__PR((hfsvol *, long, char *));
+int v_adjvalence(hfsvol *, long, int, int);
+int v_newfolder(hfsvol *, long, char *);
 
-int v_scavenge		__PR((hfsvol *));
+int v_scavenge(hfsvol *);

Modified: nonameyet/branches/cleanup/libparanoia/cdda_paranoia.h
===================================================================
--- nonameyet/branches/cleanup/libparanoia/cdda_paranoia.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/cdda_paranoia.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -75,16 +75,17 @@
 /*
  * The interface from libcdparanoia to the high level caller
  */
-extern cdrom_paranoia	*paranoia_init	__PR((void * d, int nsectors));
-extern void	paranoia_dynoverlapset	__PR((cdrom_paranoia * p,
-							int minoverlap,
-							int maxoverlap));
-extern void	paranoia_modeset	__PR((cdrom_paranoia * p, int mode));
-extern long	paranoia_seek		__PR((cdrom_paranoia * p, long seek, int mode));
-extern Int16_t	*paranoia_read		__PR((cdrom_paranoia * p, void (*callback) (long, int)));
-extern Int16_t	*paranoia_read_limited	__PR((cdrom_paranoia * p, void (*callback) (long, int), int maxretries));
-extern void	paranoia_free		__PR((cdrom_paranoia * p));
-extern void	paranoia_overlapset	__PR((cdrom_paranoia * p, long overlap));
+extern cdrom_paranoia	*paranoia_init(void * d, int nsectors);
+extern void	paranoia_dynoverlapset(cdrom_paranoia * p, int minoverlap, 
+											  int maxoverlap);
+extern void	paranoia_modeset(cdrom_paranoia * p, int mode);
+extern long	paranoia_seek(cdrom_paranoia * p, long seek, int mode);
+extern Int16_t	*paranoia_read(cdrom_paranoia * p, void (*callback) (long, int));
+extern Int16_t	*paranoia_read_limited(cdrom_paranoia * p, 
+												  void (*callback) (long, int), 
+												  int maxretries);
+extern void	paranoia_free(cdrom_paranoia * p);
+extern void	paranoia_overlapset(cdrom_paranoia * p, long overlap);
 
 #ifndef	HAVE_MEMMOVE
 #define	memmove(dst, src, size)		movebytes((src), (dst), (size))
@@ -94,13 +95,14 @@
 /*
  * The callback interface from libparanoia to the CD-ROM interface
  */
-extern long	cdda_disc_firstsector	__PR((void *d));		/* -> long sector */
-extern long	cdda_disc_lastsector	__PR((void *d));		/* -> long sector */
-extern long	cdda_read		__PR((void *d, void *buffer, long beginsector, long sectors));	/* -> long sectors */
-extern int	cdda_sector_gettrack	__PR((void *d, long sector));	/* -> int trackno */
-extern int	cdda_track_audiop	__PR((void *d, int track));	/* -> int Is audiotrack */
-extern long	cdda_track_firstsector	__PR((void *d, int track));	/* -> long sector */
-extern long	cdda_track_lastsector	__PR((void *d, int track));	/* -> long sector */
-extern int	cdda_tracks		__PR((void *d));		/* -> int tracks */
+extern long	cdda_disc_firstsector(void *d);		/* -> long sector */
+extern long	cdda_disc_lastsector(void *d);		/* -> long sector */
+/* -> long sectors */
+extern long	cdda_read(void *d, void *buffer, long beginsector, long sectors);	
+extern int	cdda_sector_gettrack(void *d, long sector);	/* -> int trackno */
+extern int	cdda_track_audiop(void *d, int track);	/* -> int Is audiotrack */
+extern long	cdda_track_firstsector(void *d, int track);	/* -> long sector */
+extern long	cdda_track_lastsector(void *d, int track);	/* -> long sector */
+extern int	cdda_tracks(void *d);		/* -> int tracks */
 
 #endif	/* _CDROM_PARANOIA_H */

Modified: nonameyet/branches/cleanup/libparanoia/gap.c
===================================================================
--- nonameyet/branches/cleanup/libparanoia/gap.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/gap.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -35,27 +35,23 @@
 #include "cdda_paranoia.h"
 #include "gap.h"
 
-long i_paranoia_overlap_r   __PR((Int16_t * buffA, Int16_t * buffB, 
-                                  long offsetA, long offsetB));
-long i_paranoia_overlap_f   __PR((Int16_t * buffA, Int16_t * buffB,
-                                  long offsetA, long offsetB,
-                                  long sizeA, long sizeB));
-int i_stutter_or_gap        __PR((Int16_t * A, Int16_t * B, long offA, 
-                                  long offB, long gap));
-void i_analyze_rift_f       __PR((Int16_t * A, Int16_t * B,
-                                  long sizeA, long sizeB,
-                                  long aoffset, long boffset,
-                                  long *matchA, long *matchB,
-                                  long *matchC));
-void i_analyze_rift_r       __PR((Int16_t * A, Int16_t * B,
-                                  long sizeA, long sizeB,
-                                  long aoffset, long boffset,
-                                  long *matchA, long *matchB,
-                                  long *matchC));
-void analyze_rift_silence_f __PR((Int16_t * A, Int16_t * B,
-                                  long sizeA, long sizeB,
-                                  long aoffset, long boffset,
-                                  long *matchA, long *matchB));
+long i_paranoia_overlap_r(Int16_t * buffA, Int16_t * buffB, long offsetA, 
+								  long offsetB);
+long i_paranoia_overlap_f(Int16_t * buffA, Int16_t * buffB, long offsetA, 
+								  long offsetB, long sizeA, long sizeB);
+int i_stutter_or_gap(Int16_t * A, Int16_t * B, long offA, long offB, long gap);
+void i_analyze_rift_f(Int16_t * A, Int16_t * B, 
+						    long sizeA, long sizeB, 
+							 long aoffset, long boffset, 
+							 long *matchA, long *matchB, long *matchC);
+void i_analyze_rift_r(Int16_t * A, Int16_t * B,
+                      long sizeA, long sizeB,
+                      long aoffset, long boffset,
+                      long *matchA, long *matchB, long *matchC);
+void analyze_rift_silence_f(Int16_t * A, Int16_t * B,
+                            long sizeA, long sizeB,
+                            long aoffset, long boffset,
+                            long *matchA, long *matchB);
 
 /*
  * Gap analysis code

Modified: nonameyet/branches/cleanup/libparanoia/gap.h
===================================================================
--- nonameyet/branches/cleanup/libparanoia/gap.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/gap.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -22,28 +22,25 @@
 #ifndef	_GAP_H_
 #define	_GAP_H_
 
-extern long	i_paranoia_overlap_r	__PR((Int16_t * buffA, Int16_t * buffB,
-						long offsetA, long offsetB));
-extern long	i_paranoia_overlap_f	__PR((Int16_t * buffA, Int16_t * buffB,
-						long offsetA, long offsetB,
-						long sizeA, long sizeB));
-extern int	i_stutter_or_gap	__PR((Int16_t * A, Int16_t * B,
-						long offA, long offB,
-						long gap));
-extern void	i_analyze_rift_f	__PR((Int16_t * A, Int16_t * B,
-						long sizeA, long sizeB,
-						long aoffset, long boffset,
-						long *matchA, long *matchB,
-						long *matchC));
-extern void	i_analyze_rift_r	__PR((Int16_t * A, Int16_t * B,
-						long sizeA, long sizeB,
-						long aoffset, long boffset,
-						long *matchA, long *matchB,
-						long *matchC));
+extern long	i_paranoia_overlap_r(Int16_t * buffA, Int16_t * buffB,
+											long offsetA, long offsetB);
+extern long	i_paranoia_overlap_f(Int16_t * buffA, Int16_t * buffB,
+											long offsetA, long offsetB,
+											long sizeA, long sizeB);
+extern int	i_stutter_or_gap(Int16_t * A, Int16_t * B,
+									  long offA, long offB,
+									  long gap);
+extern void	i_analyze_rift_f(Int16_t * A, Int16_t * B,
+									  long sizeA, long sizeB,
+									  long aoffset, long boffset,
+									  long *matchA, long *matchB, long *matchC);
+extern void	i_analyze_rift_r(Int16_t * A, Int16_t * B,
+									  long sizeA, long sizeB,
+									  long aoffset, long boffset,
+									  long *matchA, long *matchB, long *matchC);
+extern void	analyze_rift_silence_f(Int16_t * A, Int16_t * B,
+											  long sizeA, long sizeB,
+											  long aoffset, long boffset,
+											  long *matchA, long *matchB);
 
-extern void	analyze_rift_silence_f	__PR((Int16_t * A, Int16_t * B,
-						long sizeA, long sizeB,
-						long aoffset, long boffset,
-						long *matchA, long *matchB));
-
 #endif

Modified: nonameyet/branches/cleanup/libparanoia/isort.c
===================================================================
--- nonameyet/branches/cleanup/libparanoia/isort.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/isort.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -41,15 +41,14 @@
 #include "isort.h"
 #include "pmalloc.h"
 
-sort_info *sort_alloc   __PR((long size));
-void sort_unsortall     __PR((sort_info * i));
-void sort_free          __PR((sort_info * i));
-void sort_sort          __PR((sort_info * i, long sortlo, long sorthi));
-void sort_setup         __PR((sort_info * i, Int16_t * vector, long *abspos, 
-                              long size, long sortlo, long sorthi));
-sort_link *sort_getmatch __PR((sort_info * i, long post, long overlap, 
-                               int value));
-sort_link *sort_nextmatch __PR((sort_info * i, sort_link * prev));
+sort_info *sort_alloc(long size);
+void sort_unsortall(sort_info * i);
+void sort_free(sort_info * i);
+void sort_sort(sort_info * i, long sortlo, long sorthi);
+void sort_setup(sort_info * i, Int16_t * vector, long *abspos, long size, 
+					 long sortlo, long sorthi);
+sort_link *sort_getmatch(sort_info * i, long post, long overlap, int value);
+sort_link *sort_nextmatch(sort_info * i, sort_link * prev);
 
 
 sort_info *sort_alloc(long size)

Modified: nonameyet/branches/cleanup/libparanoia/isort.h
===================================================================
--- nonameyet/branches/cleanup/libparanoia/isort.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/isort.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -51,15 +51,14 @@
 
 } sort_info;
 
-extern sort_info	*sort_alloc	__PR((long size));
-extern void		sort_unsortall	__PR((sort_info * i));
-extern void		sort_setup	__PR((sort_info * i, Int16_t * vector,
-						long *abspos, long size,
-						long sortlo, long sorthi));
-extern void		sort_free	__PR((sort_info * i));
-extern sort_link	*sort_getmatch	__PR((sort_info * i, long post,
-						long overlap, int value));
-extern sort_link	*sort_nextmatch	__PR((sort_info * i, sort_link * prev));
+extern sort_info	*sort_alloc(long size);
+extern void		sort_unsortall(sort_info * i);
+extern void		sort_setup(sort_info * i, Int16_t * vector, long *abspos, 
+								  long size, long sortlo, long sorthi);
+extern void		sort_free(sort_info * i);
+extern sort_link	*sort_getmatch(sort_info * i, long post, long overlap, 
+											int value);
+extern sort_link	*sort_nextmatch(sort_info * i, sort_link * prev);
 
 #define	is(i)		((i)->size)
 #define	ib(i)		(*(i)->abspos)

Modified: nonameyet/branches/cleanup/libparanoia/overlap.c
===================================================================
--- nonameyet/branches/cleanup/libparanoia/overlap.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/overlap.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -36,14 +36,12 @@
 #include "overlap.h"
 #include "isort.h"
 
-void paranoia_resetcache    __PR((cdrom_paranoia * p));
-void paranoia_resetall      __PR((cdrom_paranoia * p));
-void i_paranoia_trim        __PR((cdrom_paranoia * p, long beginword, 
-                                  long endword));
-void offset_adjust_settings __PR((cdrom_paranoia * p, 
-                                  void (*callback)(long, int)));
-void offset_add_value       __PR((cdrom_paranoia * p, offsets * o, long value,
-						          void (*callback)(long, int)));
+void paranoia_resetcache(cdrom_paranoia *p);
+void paranoia_resetall(cdrom_paranoia *p);
+void i_paranoia_trim(cdrom_paranoia *p, long beginword, long endword);
+void offset_adjust_settings(cdrom_paranoia *p, void (*callback)(long, int));
+void offset_add_value(cdrom_paranoia *p, offsets *o, long value, 
+							 void (*callback)(long, int));
 
 /*
  * Internal cache management

Modified: nonameyet/branches/cleanup/libparanoia/overlap.h
===================================================================
--- nonameyet/branches/cleanup/libparanoia/overlap.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/overlap.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -22,14 +22,12 @@
 #ifndef	_OVERLAP_H_
 #define	_OVERLAP_H_
 
-extern	void	paranoia_resetcache	__PR((cdrom_paranoia * p));
-extern	void	paranoia_resetall	__PR((cdrom_paranoia * p));
-extern	void	i_paranoia_trim		__PR((cdrom_paranoia * p,
-						long beginword, long endword));
-extern	void	offset_adjust_settings	__PR((cdrom_paranoia * p,
-						void (*callback) (long, int)));
-extern	void	offset_add_value	__PR((cdrom_paranoia * p,
-						offsets * o, long value,
-						void (*callback) (long, int)));
+extern	void	paranoia_resetcache(cdrom_paranoia *p);
+extern	void	paranoia_resetall(cdrom_paranoia *p);
+extern	void	i_paranoia_trim(cdrom_paranoia *p, long beginword, long endword);
+extern	void	offset_adjust_settings(cdrom_paranoia *p,
+												  void (*callback) (long, int));
+extern	void	offset_add_value(cdrom_paranoia *p, offsets *o, long value,
+										  void (*callback) (long, int));
 
 #endif

Modified: nonameyet/branches/cleanup/libparanoia/p_block.c
===================================================================
--- nonameyet/branches/cleanup/libparanoia/p_block.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/p_block.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -28,41 +28,40 @@
 #include "cdda_paranoia.h"
 #include "pmalloc.h"
 
-linked_list *new_list       __PR((void *(*newp) (void),
-                                  void (*freep) (void *)));
-linked_element *add_elem    __PR((linked_list * l, void *elem));
-linked_element *new_elem    __PR((linked_list * list));
-void free_elem              __PR((linked_element * e, int free_ptr));
-void free_list              __PR((linked_list * list, int free_ptr));
-void *get_elem              __PR((linked_element * e));
-linked_list *copy_list      __PR((linked_list * list));
-static c_block *i_cblock_constructor __PR((void));
-void i_cblock_destructor    __PR((c_block * c));
-c_block *new_c_block        __PR((cdrom_paranoia * p));
-void free_c_block           __PR((c_block * c));
-static v_fragment *i_vfragment_constructor __PR((void));
-static void i_v_fragment_destructor __PR((v_fragment * v));
-v_fragment *new_v_fragment  __PR((cdrom_paranoia * p, c_block * one,
-                                 long begin, long end, int last));
-void free_v_fragment        __PR((v_fragment * v));
-c_block *c_first            __PR((cdrom_paranoia * p));
-c_block *c_last             __PR((cdrom_paranoia * p));
-c_block *c_next             __PR((c_block * c));
-c_block *c_prev             __PR((c_block * c));
-v_fragment *v_first         __PR((cdrom_paranoia * p));
-v_fragment *v_last          __PR((cdrom_paranoia * p));
-v_fragment *v_next          __PR((v_fragment * v));
-v_fragment *v_prev          __PR((v_fragment * v));
-void recover_cache          __PR((cdrom_paranoia * p));
-Int16_t *v_buffer           __PR((v_fragment * v));
-c_block *c_alloc            __PR((Int16_t * vector, long begin, long size));
-void c_set                  __PR((c_block * v, long begin));
-void c_remove               __PR((c_block * v, long cutpos, long cutsize));
-void c_overwrite            __PR((c_block * v, long pos, Int16_t * b, long size));
-void c_append               __PR((c_block * v, Int16_t * vector, long size));
-void c_removef              __PR((c_block * v, long cut));
-void i_paranoia_firstlast   __PR((cdrom_paranoia * p));
-cdrom_paranoia *paranoia_init __PR((void * d, int nsectors));
+linked_list 	*new_list(void *(*newp) (void), void (*freep) (void *));
+linked_element *add_elem(linked_list *l, void *elem);
+linked_element *new_elem(linked_list *list);
+void 				free_elem(linked_element *e, int free_ptr);
+void 				free_list(linked_list *list, int free_ptr);
+void 				*get_elem(linked_element *e);
+linked_list 	*copy_list(linked_list *list);
+static c_block *i_cblock_constructor(void);
+void 				i_cblock_destructor(c_block *c);
+c_block 			*new_c_block(cdrom_paranoia *p);
+void 				free_c_block(c_block *c);
+static v_fragment *i_vfragment_constructor(void);
+static void 	i_v_fragment_destructor(v_fragment *v);
+v_fragment 		*new_v_fragment(cdrom_paranoia *p, c_block *one, long begin, 
+										 long end, int last);
+void 				free_v_fragment(v_fragment *v);
+c_block 			*c_first(cdrom_paranoia *p);
+c_block 			*c_last(cdrom_paranoia *p);
+c_block 			*c_next(c_block *c);
+c_block 			*c_prev(c_block *c);
+v_fragment 		*v_first(cdrom_paranoia *p);
+v_fragment 		*v_last(cdrom_paranoia *p);
+v_fragment 		*v_next(v_fragment *v);
+v_fragment 		*v_prev(v_fragment *v);
+void 				recover_cache(cdrom_paranoia *p);
+Int16_t 			*v_buffer(v_fragment *v);
+c_block 			*c_alloc(Int16_t *vector, long begin, long size);
+void 				c_set(c_block *v, long begin);
+void 				c_remove(c_block *v, long cutpos, long cutsize);
+void 				c_overwrite(c_block *v, long pos, Int16_t *b, long size);
+void 				c_append(c_block *v, Int16_t *vector, long size);
+void 				c_removef(c_block *v, long cut);
+void 				i_paranoia_firstlast(cdrom_paranoia *p);
+cdrom_paranoia *paranoia_init(void *d, int nsectors);
 
 
 linked_list *new_list(void *(*newp)(void), void (*freep)(void *))
@@ -149,7 +148,7 @@
 
 /**** C_block stuff ******************************************************/
 
-#define	vp_cblock_constructor_func ((void*(*)__PR((void)))i_cblock_constructor)
+#define	vp_cblock_constructor_func ((void*(*)(void))i_cblock_constructor)
 static c_block *i_cblock_constructor()
 {
 	c_block		*ret = _pcalloc(1, sizeof (c_block));
@@ -157,7 +156,7 @@
 	return (ret);
 }
 
-#define	vp_cblock_destructor_func ((void(*)__PR((void*)))i_cblock_destructor)
+#define	vp_cblock_destructor_func ((void(*)(void*))i_cblock_destructor)
 void i_cblock_destructor(c_block *c)
 {
 	if (c) {
@@ -198,7 +197,7 @@
 	free_elem(c->e, 1);
 }
 
-#define	vp_vfragment_constructor_func ((void*(*)__PR((void)))i_vfragment_constructor)
+#define	vp_vfragment_constructor_func ((void*(*)(void))i_vfragment_constructor)
 static v_fragment *i_vfragment_constructor()
 {
 	v_fragment	*ret = _pcalloc(1, sizeof (v_fragment));
@@ -206,7 +205,7 @@
 	return (ret);
 }
 
-#define	vp_v_fragment_destructor_func ((void(*)__PR((void*)))i_v_fragment_destructor)
+#define	vp_v_fragment_destructor_func ((void(*)(void*))i_v_fragment_destructor)
 static void i_v_fragment_destructor(v_fragment *v)
 {
 	_pfree(v);

Modified: nonameyet/branches/cleanup/libparanoia/p_block.h
===================================================================
--- nonameyet/branches/cleanup/libparanoia/p_block.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/p_block.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -41,8 +41,8 @@
 	struct linked_element	*head;
 	struct linked_element	*tail;
 
-	void			*(*new_poly)	__PR((void));
-	void			(*free_poly)	__PR((void *poly));
+	void			*(*new_poly)(void);
+	void			(*free_poly)(void *poly);
 	long			current;
 	long			active;
 
@@ -57,14 +57,14 @@
 	int			stamp;
 } linked_element;
 
-extern linked_list	*new_list	__PR((void *(*newp) (void),
-						void (*freep) (void *)));
-extern linked_element	*new_elem	__PR((linked_list * list));
-extern linked_element	*add_elem	__PR((linked_list * list, void *elem));
-extern void		free_list	__PR((linked_list * list, int free_ptr));	/* unlink or free */
-extern void		free_elem	__PR((linked_element * e, int free_ptr));	/* unlink or free */
-extern void		*get_elem	__PR((linked_element * e));
-extern linked_list	*copy_list	__PR((linked_list * list));	/* shallow; doesn't copy */
+extern linked_list	*new_list(void *(*newp) (void),
+										 void (*freep) (void *));
+extern linked_element	*new_elem(linked_list *list);
+extern linked_element	*add_elem(linked_list *list, void *elem);
+extern void		free_list(linked_list *list, int free_ptr);	/* unlink or free */
+extern void		free_elem(linked_element *e, int free_ptr);	/* unlink or free */
+extern void		*get_elem(linked_element *e);
+extern linked_list	*copy_list(linked_list *list);	/* shallow; doesn't copy */
 									/* contained structures */
 
 typedef struct c_block {
@@ -92,9 +92,9 @@
 	struct linked_element	*e;
 } c_block;
 
-extern void	free_c_block		__PR((c_block * c));
-extern void	i_cblock_destructor	__PR((c_block * c));
-extern c_block	*new_c_block		__PR((struct cdrom_paranoia * p));
+extern void	free_c_block(c_block *c);
+extern void	i_cblock_destructor(c_block *c);
+extern c_block	*new_c_block(struct cdrom_paranoia *p);
 
 typedef struct v_fragment {
 	c_block		*one;
@@ -112,22 +112,21 @@
 
 } v_fragment;
 
-extern void	free_v_fragment		__PR((v_fragment * c));
-extern v_fragment *new_v_fragment	__PR((struct cdrom_paranoia * p,
-						c_block * one,
-						long begin, long end,
-						int lastsector));
-extern Int16_t	*v_buffer		__PR((v_fragment * v));
+extern void	free_v_fragment(v_fragment *c);
+extern v_fragment *new_v_fragment(struct cdrom_paranoia *p, c_block *one,
+											 long begin, long end,
+											 int lastsector);
+extern Int16_t	*v_buffer(v_fragment *v);
 
-extern c_block	*c_first		__PR((struct cdrom_paranoia * p));
-extern c_block	*c_last			__PR((struct cdrom_paranoia * p));
-extern c_block	*c_next			__PR((c_block * c));
-extern c_block	*c_prev			__PR((c_block * c));
+extern c_block	*c_first(struct cdrom_paranoia *p);
+extern c_block	*c_last(struct cdrom_paranoia *p);
+extern c_block	*c_next(c_block *c);
+extern c_block	*c_prev(c_block *c);
 
-extern v_fragment *v_first		__PR((struct cdrom_paranoia * p));
-extern v_fragment *v_last		__PR((struct cdrom_paranoia * p));
-extern v_fragment *v_next		__PR((v_fragment * v));
-extern v_fragment *v_prev		__PR((v_fragment * v));
+extern v_fragment *v_first(struct cdrom_paranoia *p);
+extern v_fragment *v_last(struct cdrom_paranoia *p);
+extern v_fragment *v_next(v_fragment *v);
+extern v_fragment *v_prev(v_fragment *v);
 
 typedef struct root_block {
 	long		returnedlimit;
@@ -182,18 +181,13 @@
 
 } cdrom_paranoia;
 
-extern c_block	*c_alloc		__PR((Int16_t * vector,
-						long begin, long size));
-extern void	c_set			__PR((c_block * v, long begin));
-extern void	c_insert		__PR((c_block * v, long pos,
-						Int16_t * b, long size));
-extern void	c_remove		__PR((c_block * v, long cutpos,
-						long cutsize));
-extern void	c_overwrite		__PR((c_block * v, long pos,
-						Int16_t * b, long size));
-extern void	c_append		__PR((c_block * v, Int16_t * vector,
-						long size));
-extern void	c_removef		__PR((c_block * v, long cut));
+extern c_block	*c_alloc(Int16_t *vector, long begin, long size);
+extern void	c_set(c_block *v, long begin);
+extern void	c_insert(c_block *v, long pos, Int16_t *b, long size);
+extern void	c_remove(c_block *v, long cutpos, long cutsize);
+extern void	c_overwrite(c_block *v, long pos, Int16_t *b, long size);
+extern void	c_append(c_block *v, Int16_t *vector, long size);
+extern void	c_removef(c_block *v, long cut);
 
 #define	ce(v)	((v)->begin + (v)->size)
 #define	cb(v)	((v)->begin)
@@ -202,8 +196,8 @@
 /*
  * pos here is vector position from zero
  */
-extern void	recover_cache		__PR((cdrom_paranoia * p));
-extern void	i_paranoia_firstlast	__PR((cdrom_paranoia * p));
+extern void	recover_cache(cdrom_paranoia *p);
+extern void	i_paranoia_firstlast(cdrom_paranoia *p);
 
 #define	cv(c)	((c)->vector)
 

Modified: nonameyet/branches/cleanup/libparanoia/paranoia.c
===================================================================
--- nonameyet/branches/cleanup/libparanoia/paranoia.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/paranoia.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -90,62 +90,61 @@
 	long		end;
 } sync_result;
 
-static inline long	re      __PR((root_block * root));
-static inline long rb       __PR((root_block * root));
-static inline long rs       __PR((root_block * root));
-static inline Int16_t *rv   __PR((root_block * root));
-static inline long i_paranoia_overlap __PR((Int16_t * buffA, Int16_t * buffB,
-                                            long offsetA, long offsetB,
-                                            long sizeA, long sizeB,
-                                            long *ret_begin, long *ret_end));
-static inline long i_paranoia_overlap2 __PR((Int16_t * buffA, Int16_t * buffB,
-                                             Uchar *flagsA, Uchar *flagsB,
-                                             long offsetA, long offsetB,
-                                             long sizeA, long sizeB,
-                                             long *ret_begin, long *ret_end));
-static inline long do_const_sync __PR((c_block * A,
-                                       sort_info * B, Uchar *flagB,
-                                       long posA, long posB,
-                                       long *begin, long *end, long *offset));
-static inline long try_sort_sync __PR((cdrom_paranoia * p,
-                                       sort_info * A, Uchar *Aflags,
-                                       c_block * B,
-                                       long post, long *begin, long *end,
-                                       long *offset, void (*callback) (long, int)));
-static inline void stage1_matched __PR((c_block * old, c_block * new,
-                                 long matchbegin, long matchend,
-                                 long matchoffset, void (*callback) (long, int)));
-static long i_iterate_stage1    __PR((cdrom_paranoia * p, c_block * old, c_block * new,
-                                      void (*callback) (long, int)));
-static long i_stage1            __PR((cdrom_paranoia * p, c_block * new,
-                                      void (*callback) (long, int)));
-static long i_iterate_stage2    __PR((cdrom_paranoia * p, v_fragment * v,
-                                      sync_result *r, void (*callback)(long, int)));
-static void i_silence_test      __PR((root_block * root));
-static long i_silence_match     __PR((root_block * root, v_fragment * v,
-                                      void (*callback) (long, int)));
-static long i_stage2_each       __PR((root_block * root, v_fragment * v,
-                                      void (*callback) (long, int)));
-static int i_init_root          __PR((root_block * root, v_fragment * v, 
-                                      long begin, void (*callback)(long, int)));
-static int vsort                __PR((const void *a, const void *b));
-static int i_stage2             __PR((cdrom_paranoia * p, long beginword, 
-                                      long endword, void (*callback)(long, int)));
-static void i_end_case          __PR((cdrom_paranoia * p, long endword, 
-                                      void (*callback)(long, int)));
-static void verify_skip_case    __PR((cdrom_paranoia * p, 
-                                      void (*callback)(long, int)));
-void paranoia_free              __PR((cdrom_paranoia * p));
-void paranoia_modeset           __PR((cdrom_paranoia * p, int enable));
-long paranoia_seek              __PR((cdrom_paranoia * p, long seek, int mode));
-c_block *i_read_c_block         __PR((cdrom_paranoia * p, long beginword, 
-                                      long endword, void (*callback)(long,int)));
-Int16_t *paranoia_read          __PR((cdrom_paranoia * p, 
-                                      void (*callback)(long, int)));
-Int16_t *paranoia_read_limited  __PR((cdrom_paranoia * p, 
-                                      void (*callback)(long, int),
-                                      int max_retries));
-void paranoia_overlapset        __PR((cdrom_paranoia * p, long overlap));
+static inline long re(root_block *root);
+static inline long rb(root_block *root);
+static inline long rs(root_block *root);
+static inline Int16_t *rv(root_block *root);
+static inline long i_paranoia_overlap(Int16_t *buffA, Int16_t *buffB,
+                                      long offsetA, long offsetB,
+                                      long sizeA, long sizeB,
+                                      long *ret_begin, long *ret_end);
+static inline long i_paranoia_overlap2(Int16_t *buffA, Int16_t *buffB,
+                                       Uchar *flagsA, Uchar *flagsB,
+                                       long offsetA, long offsetB,
+                                       long sizeA, long sizeB,
+                                       long *ret_begin, long *ret_end);
+static inline long do_const_sync(c_block *A,
+                                 sort_info *B, Uchar *flagB,
+                                 long posA, long posB,
+                                 long *begin, long *end, long *offset);
+static inline long try_sort_sync(cdrom_paranoia *p,
+                                 sort_info *A, Uchar *Aflags,
+                                 c_block *B,
+                                 long post, long *begin, long *end,
+                                 long *offset, void (*callback) (long, int));
+static inline void stage1_matched(c_block *old, c_block *new,
+                                  long matchbegin, long matchend, 
+											 long matchoffset, 
+											 void (*callback) (long, int));
+static long i_iterate_stage1(cdrom_paranoia *p, c_block *old, c_block *new,
+                             void (*callback) (long, int));
+static long i_stage1(cdrom_paranoia *p, c_block *new, 
+							void (*callback) (long, int));
+static long i_iterate_stage2(cdrom_paranoia *p, v_fragment *v, sync_result *r, 
+									  void (*callback)(long, int));
+static void i_silence_test(root_block *root);
+static long i_silence_match(root_block *root, v_fragment *v,
+                            void (*callback) (long, int));
+static long i_stage2_each(root_block *root, v_fragment *v,
+                          void (*callback) (long, int));
+static int i_init_root(root_block *root, v_fragment *v, 
+                       long begin, void (*callback)(long, int));
+static int vsort(const void *a, const void *b);
+static int i_stage2(cdrom_paranoia *p, long beginword, long endword, 
+						  void (*callback)(long, int));
+static void i_end_case(cdrom_paranoia *p, long endword, 
+                       void (*callback)(long, int));
+static void verify_skip_case(cdrom_paranoia *p, 
+                             void (*callback)(long, int));
+void paranoia_free(cdrom_paranoia *p);
+void paranoia_modeset(cdrom_paranoia *p, int enable);
+long paranoia_seek(cdrom_paranoia *p, long seek, int mode);
+c_block *i_read_c_block(cdrom_paranoia *p, long beginword, long endword, 
+								void (*callback)(long,int));
+Int16_t *paranoia_read(cdrom_paranoia *p, void (*callback)(long, int));
+Int16_t *paranoia_read_limited(cdrom_paranoia *p, void (*callback)(long, int),
+                               int max_retries);
+void paranoia_overlapset(cdrom_paranoia *p, long overlap);
 
 
 static inline long re(root_block *root)
@@ -409,7 +408,7 @@
 
 }
 
-#define	CB_NULL		(void (*) __PR((long, int)))0
+#define	CB_NULL		(void (*)(long, int))0
 
 static long 
 i_iterate_stage1(cdrom_paranoia *p, c_block *old, c_block *new, 

Modified: nonameyet/branches/cleanup/libparanoia/pmalloc.h
===================================================================
--- nonameyet/branches/cleanup/libparanoia/pmalloc.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libparanoia/pmalloc.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -34,9 +34,9 @@
 #ifndef	_PMALLOC_H
 #define	_PMALLOC_H
 
-extern	void	_pfree		__PR((void *ptr));
-extern	void	*_pmalloc	__PR((size_t size));
-extern	void	*_pcalloc	__PR((size_t nelem, size_t elsize));
-extern	void	*_prealloc	__PR((void *ptr, size_t size));
+extern	void	_pfree(void *ptr);
+extern	void	*_pmalloc(size_t size);
+extern	void	*_pcalloc(size_t nelem, size_t elsize);
+extern	void	*_prealloc(void *ptr, size_t size);
 
 #endif	/* _PMALLOC_H */

Modified: nonameyet/branches/cleanup/librscg/scsi-remote.c
===================================================================
--- nonameyet/branches/cleanup/librscg/scsi-remote.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/librscg/scsi-remote.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -112,57 +112,55 @@
 LOCAL	char	_scg_trans_version[] = "remote-1.18";	/* The version for remote SCSI	*/
 LOCAL	char	_scg_auth_cdrkit[]	= "cdrkit-team";	/* The author for this module	*/
 
-LOCAL	int	scgo_rsend		__PR((SCSI *scgp));
-LOCAL	char *	scgo_rversion		__PR((SCSI *scgp, int what));
-LOCAL	int	scgo_rhelp		__PR((SCSI *scgp, FILE *f));
-LOCAL	int	scgo_ropen		__PR((SCSI *scgp, char *device));
-LOCAL	int	scgo_rclose		__PR((SCSI *scgp));
-LOCAL	long	scgo_rmaxdma		__PR((SCSI *scgp, long amt));
-LOCAL	void *	scgo_rgetbuf		__PR((SCSI *scgp, long amt));
-LOCAL	void	scgo_rfreebuf		__PR((SCSI *scgp));
-LOCAL	BOOL	scgo_rhavebus		__PR((SCSI *scgp, int busno));
-LOCAL	int	scgo_rfileno		__PR((SCSI *scgp, int busno, int tgt, int tlun));
-LOCAL	int	scgo_rinitiator_id	__PR((SCSI *scgp));
-LOCAL	int	scgo_risatapi		__PR((SCSI *scgp));
-LOCAL	int	scgo_rreset		__PR((SCSI *scgp, int what));
+LOCAL	int	scgo_rsend(SCSI *scgp);
+LOCAL	char *	scgo_rversion(SCSI *scgp, int what);
+LOCAL	int	scgo_rhelp(SCSI *scgp, FILE *f);
+LOCAL	int	scgo_ropen(SCSI *scgp, char *device);
+LOCAL	int	scgo_rclose(SCSI *scgp);
+LOCAL	long	scgo_rmaxdma(SCSI *scgp, long amt);
+LOCAL	void *	scgo_rgetbuf(SCSI *scgp, long amt);
+LOCAL	void	scgo_rfreebuf(SCSI *scgp);
+LOCAL	BOOL	scgo_rhavebus(SCSI *scgp, int busno);
+LOCAL	int	scgo_rfileno(SCSI *scgp, int busno, int tgt, int tlun);
+LOCAL	int	scgo_rinitiator_id(SCSI *scgp);
+LOCAL	int	scgo_risatapi(SCSI *scgp);
+LOCAL	int	scgo_rreset(SCSI *scgp, int what);
 
 /*
  * XXX We should rethink the fd parameter now that we introduced
  * XXX the rscsirchar() function and most access of remfd is done
  * XXX via scglocal(scgp)->remfd.
  */
-LOCAL	void	rscsiabrt		__PR((int sig));
-LOCAL	int	rscsigetconn		__PR((SCSI *scgp, char *host));
-LOCAL	char	*rscsiversion		__PR((SCSI *scgp, int fd, int what));
-LOCAL	int	rscsiopen		__PR((SCSI *scgp, int fd, char *fname));
-LOCAL	int	rscsiclose		__PR((SCSI *scgp, int fd));
-LOCAL	int	rscsimaxdma		__PR((SCSI *scgp, int fd, long amt));
-LOCAL	int	rscsigetbuf		__PR((SCSI *scgp, int fd, long amt));
-LOCAL	int	rscsifreebuf		__PR((SCSI *scgp, int fd));
-LOCAL	int	rscsihavebus		__PR((SCSI *scgp, int fd, int bus));
-LOCAL	int	rscsifileno		__PR((SCSI *scgp, int fd, int busno, int tgt, int tlun));
-LOCAL	int	rscsiinitiator_id	__PR((SCSI *scgp, int fd));
-LOCAL	int	rscsiisatapi		__PR((SCSI *scgp, int fd));
-LOCAL	int	rscsireset		__PR((SCSI *scgp, int fd, int what));
-LOCAL	int	rscsiscmd		__PR((SCSI *scgp, int fd, struct scg_cmd *sp));
-LOCAL	int	rscsifillrbuf		__PR((SCSI *scgp));
-LOCAL	int	rscsirchar		__PR((SCSI *scgp, char *cp));
-LOCAL	int	rscsireadbuf		__PR((SCSI *scgp, int fd, char *buf, int count));
-LOCAL	void	rscsivoidarg		__PR((SCSI *scgp, int fd, int count));
-LOCAL	int	rscsicmd		__PR((SCSI *scgp, int fd, char *name, char *cbuf));
-LOCAL	void	rscsisendcmd		__PR((SCSI *scgp, int fd, char *name, char *cbuf));
-LOCAL	int	rscsigetline		__PR((SCSI *scgp, int fd, char *line, int count));
-LOCAL	int	rscsireadnum		__PR((SCSI *scgp, int fd));
-LOCAL	int	rscsigetstatus		__PR((SCSI *scgp, int fd, char *name));
-LOCAL	int	rscsiaborted		__PR((SCSI *scgp, int fd));
+LOCAL	void	rscsiabrt(int sig);
+LOCAL	int	rscsigetconn(SCSI *scgp, char *host);
+LOCAL	char	*rscsiversion(SCSI *scgp, int fd, int what);
+LOCAL	int	rscsiopen(SCSI *scgp, int fd, char *fname);
+LOCAL	int	rscsiclose(SCSI *scgp, int fd);
+LOCAL	int	rscsimaxdma(SCSI *scgp, int fd, long amt);
+LOCAL	int	rscsigetbuf(SCSI *scgp, int fd, long amt);
+LOCAL	int	rscsifreebuf(SCSI *scgp, int fd);
+LOCAL	int	rscsihavebus(SCSI *scgp, int fd, int bus);
+LOCAL	int	rscsifileno(SCSI *scgp, int fd, int busno, int tgt, int tlun);
+LOCAL	int	rscsiinitiator_id(SCSI *scgp, int fd);
+LOCAL	int	rscsiisatapi(SCSI *scgp, int fd);
+LOCAL	int	rscsireset(SCSI *scgp, int fd, int what);
+LOCAL	int	rscsiscmd(SCSI *scgp, int fd, struct scg_cmd *sp);
+LOCAL	int	rscsifillrbuf(SCSI *scgp);
+LOCAL	int	rscsirchar(SCSI *scgp, char *cp);
+LOCAL	int	rscsireadbuf(SCSI *scgp, int fd, char *buf, int count);
+LOCAL	void	rscsivoidarg(SCSI *scgp, int fd, int count);
+LOCAL	int	rscsicmd(SCSI *scgp, int fd, char *name, char *cbuf);
+LOCAL	void	rscsisendcmd(SCSI *scgp, int fd, char *name, char *cbuf);
+LOCAL	int	rscsigetline(SCSI *scgp, int fd, char *line, int count);
+LOCAL	int	rscsireadnum(SCSI *scgp, int fd);
+LOCAL	int	rscsigetstatus(SCSI *scgp, int fd, char *name);
+LOCAL	int	rscsiaborted(SCSI *scgp, int fd);
 #ifdef	USE_RCMD_RSH
-LOCAL	int	_rcmdrsh		__PR((char **ahost, int inport,
-						const char *locuser,
-						const char *remuser,
-						const char *cmd,
-						const char *rsh));
+LOCAL	int	_rcmdrsh(char **ahost, int inport, const char *locuser,
+							const char *remuser, const char *cmd,
+							const char *rsh);
 #ifdef	HAVE_GETPPRIV
-LOCAL	BOOL	ppriv_ok		__PR((void));
+LOCAL	BOOL	ppriv_ok(void);
 #endif
 #endif
 

Modified: nonameyet/branches/cleanup/libscg/rdummy.c
===================================================================
--- nonameyet/branches/cleanup/libscg/rdummy.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/rdummy.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -42,7 +42,7 @@
 
 #include <scg/scsitransp.h>
 
-EXPORT	scg_ops_t *scg_remote	__PR((void));
+scg_ops_t *scg_remote(void);
 
 EXPORT scg_ops_t *
 scg_remote()

Modified: nonameyet/branches/cleanup/libscg/scg/scgops.h
===================================================================
--- nonameyet/branches/cleanup/libscg/scg/scgops.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scg/scgops.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -37,26 +37,26 @@
 #endif
 
 typedef struct scg_ops {
-	int	(*scgo_send)		__PR((SCSI *scgp));
+	int	(*scgo_send)(SCSI *scgp);
 
-	char *	(*scgo_version)		__PR((SCSI *scgp, int what));
+	char *	(*scgo_version)(SCSI *scgp, int what);
 #ifdef	EOF	/* stdio.h has been included */
-	int	(*scgo_help)		__PR((SCSI *scgp, FILE *f));
+	int	(*scgo_help)(SCSI *scgp, FILE *f);
 #else
-	int	(*scgo_help)		__PR((SCSI *scgp, void *f));
+	int	(*scgo_help)(SCSI *scgp, void *f);
 #endif
-	int	(*scgo_open)		__PR((SCSI *scgp, char *device));
-	int	(*scgo_close)		__PR((SCSI *scgp));
-	long	(*scgo_maxdma)		__PR((SCSI *scgp, long amt));
-	void *	(*scgo_getbuf)		__PR((SCSI *scgp, long amt));
-	void	(*scgo_freebuf)		__PR((SCSI *scgp));
+	int	(*scgo_open)(SCSI *scgp, char *device);
+	int	(*scgo_close)(SCSI *scgp);
+	long	(*scgo_maxdma)(SCSI *scgp, long amt);
+	void *	(*scgo_getbuf)(SCSI *scgp, long amt);
+	void	(*scgo_freebuf)(SCSI *scgp);
 
 
-	BOOL	(*scgo_havebus)		__PR((SCSI *scgp, int busno));
-	int	(*scgo_fileno)		__PR((SCSI *scgp, int busno, int tgt, int tlun));
-	int	(*scgo_initiator_id)	__PR((SCSI *scgp));
-	int	(*scgo_isatapi)		__PR((SCSI *scgp));
-	int	(*scgo_reset)		__PR((SCSI *scgp, int what));
+	BOOL	(*scgo_havebus)(SCSI *scgp, int busno);
+	int	(*scgo_fileno)(SCSI *scgp, int busno, int tgt, int tlun);
+	int	(*scgo_initiator_id)(SCSI *scgp);
+	int	(*scgo_isatapi)(SCSI *scgp);
+	int	(*scgo_reset)(SCSI *scgp, int what);
 } scg_ops_t;
 
 #define	SCGO_SEND(scgp)				(*(scgp)->ops->scgo_send)(scgp)

Modified: nonameyet/branches/cleanup/libscg/scg/scsitransp.h
===================================================================
--- nonameyet/branches/cleanup/libscg/scg/scsitransp.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scg/scsitransp.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -50,7 +50,7 @@
 #include <scg/scgops.h>
 #endif
 
-typedef	int	(*scg_cb_t)	__PR((void *));
+typedef	int	(*scg_cb_t)(void *);
 
 struct scg_scsi {
 	scg_ops_t *ops;		/* Ptr to low level SCSI transport ops	*/
@@ -149,116 +149,112 @@
 /*
  * From scsitransp.c:
  */
-extern	char	*scg_version		__PR((SCSI *scgp, int what));
-extern	int	scg__open		__PR((SCSI *scgp, char *device));
-extern	int	scg__close		__PR((SCSI *scgp));
-extern	BOOL	scg_havebus		__PR((SCSI *scgp, int));
-extern	int	scg_initiator_id	__PR((SCSI *scgp));
-extern	int	scg_isatapi		__PR((SCSI *scgp));
-extern	int	scg_reset		__PR((SCSI *scgp, int what));
-extern	void	*scg_getbuf		__PR((SCSI *scgp, long));
-extern	void	scg_freebuf		__PR((SCSI *scgp));
-extern	long	scg_bufsize		__PR((SCSI *scgp, long));
-extern	void	scg_setnonstderrs	__PR((SCSI *scgp, const char **));
-extern	BOOL	scg_yes			__PR((char *));
-extern	int	scg_cmd			__PR((SCSI *scgp));
-extern	void	scg_vhead		__PR((SCSI *scgp));
-extern	int	scg_svhead		__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	int	scg_vtail		__PR((SCSI *scgp));
-extern	int	scg_svtail		__PR((SCSI *scgp, int *retp, char *buf, int maxcnt));
-extern	void	scg_vsetup		__PR((SCSI *scgp));
-extern	int	scg_getresid		__PR((SCSI *scgp));
-extern	int	scg_getdmacnt		__PR((SCSI *scgp));
-extern	BOOL	scg_cmd_err		__PR((SCSI *scgp));
-extern	void	scg_printerr		__PR((SCSI *scgp));
+extern	char	*scg_version(SCSI *scgp, int what);
+extern	int	scg__open(SCSI *scgp, char *device);
+extern	int	scg__close(SCSI *scgp);
+extern	BOOL	scg_havebus(SCSI *scgp, int);
+extern	int	scg_initiator_id(SCSI *scgp);
+extern	int	scg_isatapi(SCSI *scgp);
+extern	int	scg_reset(SCSI *scgp, int what);
+extern	void	*scg_getbuf(SCSI *scgp, long);
+extern	void	scg_freebuf(SCSI *scgp);
+extern	long	scg_bufsize(SCSI *scgp, long);
+extern	void	scg_setnonstderrs(SCSI *scgp, const char **);
+extern	BOOL	scg_yes(char *);
+extern	int	scg_cmd(SCSI *scgp);
+extern	void	scg_vhead(SCSI *scgp);
+extern	int	scg_svhead(SCSI *scgp, char *buf, int maxcnt);
+extern	int	scg_vtail(SCSI *scgp);
+extern	int	scg_svtail(SCSI *scgp, int *retp, char *buf, int maxcnt);
+extern	void	scg_vsetup(SCSI *scgp);
+extern	int	scg_getresid(SCSI *scgp);
+extern	int	scg_getdmacnt(SCSI *scgp);
+extern	BOOL	scg_cmd_err(SCSI *scgp);
+extern	void	scg_printerr(SCSI *scgp);
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	scg_fprinterr		__PR((SCSI *scgp, FILE *f));
+extern	void	scg_fprinterr(SCSI *scgp, FILE *f);
 #endif
-extern	int	scg_sprinterr		__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	int	scg__sprinterr		__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	void	scg_printcdb		__PR((SCSI *scgp));
-extern	int	scg_sprintcdb		__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	void	scg_printwdata		__PR((SCSI *scgp));
-extern	int	scg_sprintwdata		__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	void	scg_printrdata		__PR((SCSI *scgp));
-extern	int	scg_sprintrdata		__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	void	scg_printresult		__PR((SCSI *scgp));
-extern	int	scg_sprintresult 	__PR((SCSI *scgp, char *buf, int maxcnt));
-extern	void	scg_printstatus		__PR((SCSI *scgp));
-extern	int	scg_sprintstatus 	__PR((SCSI *scgp, char *buf, int maxcnt));
+extern	int	scg_sprinterr(SCSI *scgp, char *buf, int maxcnt);
+extern	int	scg__sprinterr(SCSI *scgp, char *buf, int maxcnt);
+extern	void	scg_printcdb(SCSI *scgp);
+extern	int	scg_sprintcdb(SCSI *scgp, char *buf, int maxcnt);
+extern	void	scg_printwdata(SCSI *scgp);
+extern	int	scg_sprintwdata(SCSI *scgp, char *buf, int maxcnt);
+extern	void	scg_printrdata(SCSI *scgp);
+extern	int	scg_sprintrdata(SCSI *scgp, char *buf, int maxcnt);
+extern	void	scg_printresult(SCSI *scgp);
+extern	int	scg_sprintresult(SCSI *scgp, char *buf, int maxcnt);
+extern	void	scg_printstatus(SCSI *scgp);
+extern	int	scg_sprintstatus(SCSI *scgp, char *buf, int maxcnt);
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	scg_fprbytes		__PR((FILE *, char *, unsigned char *, int));
-extern	void	scg_fprascii		__PR((FILE *, char *, unsigned char *, int));
+extern	void	scg_fprbytes(FILE *, char *, unsigned char *, int);
+extern	void	scg_fprascii(FILE *, char *, unsigned char *, int);
 #endif
-extern	void	scg_prbytes		__PR((char *, unsigned char *, int));
-extern	void	scg_prascii		__PR((char *, unsigned char *, int));
-extern	int	scg_sprbytes		__PR((char *buf, int maxcnt, char *, unsigned char *, int));
-extern	int	scg_sprascii		__PR((char *buf, int maxcnt, char *, unsigned char *, int));
+extern	void	scg_prbytes(char *, unsigned char *, int);
+extern	void	scg_prascii(char *, unsigned char *, int);
+extern	int	scg_sprbytes(char *buf, int maxcnt, char *, unsigned char *, int);
+extern	int	scg_sprascii(char *buf, int maxcnt, char *, unsigned char *, int);
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	scg_fprsense		__PR((FILE *f, unsigned char *, int));
+extern	void	scg_fprsense(FILE *f, unsigned char *, int);
 #endif
-extern	void	scg_prsense		__PR((unsigned char *, int));
-extern	int	scg_sprsense		__PR((char *buf, int maxcnt, unsigned char *, int));
-extern	int	scg_cmd_status		__PR((SCSI *scgp));
-extern	int	scg_sense_key		__PR((SCSI *scgp));
-extern	int	scg_sense_code		__PR((SCSI *scgp));
-extern	int	scg_sense_qual		__PR((SCSI *scgp));
+extern	void	scg_prsense(unsigned char *, int);
+extern	int	scg_sprsense(char *buf, int maxcnt, unsigned char *, int);
+extern	int	scg_cmd_status(SCSI *scgp);
+extern	int	scg_sense_key(SCSI *scgp);
+extern	int	scg_sense_code(SCSI *scgp);
+extern	int	scg_sense_qual(SCSI *scgp);
 #ifdef	_SCG_SCSIREG_H
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	scg_fprintdev		__PR((FILE *, struct scsi_inquiry *));
+extern	void	scg_fprintdev(FILE *, struct scsi_inquiry *);
 #endif
-extern	void	scg_printdev		__PR((struct scsi_inquiry *));
+extern	void	scg_printdev(struct scsi_inquiry *);
 #endif
-extern	int	scg_printf		__PR((SCSI *scgp, const char *form, ...));
-extern	int	scg_errflush		__PR((SCSI *scgp));
+extern	int	scg_printf(SCSI *scgp, const char *form, ...);
+extern	int	scg_errflush(SCSI *scgp);
 #ifdef	EOF	/* stdio.h has been included */
-extern	int	scg_errfflush		__PR((SCSI *scgp, FILE *f));
+extern	int	scg_errfflush(SCSI *scgp, FILE *f);
 #endif
 
 /*
  * From scsierrmsg.c:
  */
-extern	const char	*scg_sensemsg	__PR((int, int, int,
-						const char **, char *, int maxcnt));
+extern	const char	*scg_sensemsg(int, int, int, const char **, char *, 
+											  int maxcnt);
 #ifdef	_SCG_SCSISENSE_H
-extern	int		scg__errmsg	__PR((SCSI *scgp, char *obuf, int maxcnt,
-						struct scsi_sense *,
-						struct scsi_status *,
-						int));
+extern	int		scg__errmsg(SCSI *scgp, char *obuf, int maxcnt,
+										struct scsi_sense *, struct scsi_status *, int);
 #endif
 
 /*
  * From scsiopen.c:
  */
 #ifdef	EOF	/* stdio.h has been included */
-extern	int	scg_help	__PR((FILE *f));
+extern	int	scg_help(FILE *f);
 #endif
-extern	SCSI	*scg_open	__PR((char *scsidev, char *errs, int slen, int odebug, int be_verbose));
-extern	int	scg_close	__PR((SCSI * scgp));
-extern	void	scg_settimeout	__PR((SCSI * scgp, int timeout));
-extern	SCSI	*scg_smalloc	__PR((void));
-extern	void	scg_sfree	__PR((SCSI *scgp));
+extern	SCSI	*scg_open(char *scsidev, char *errs, int slen, int odebug, 
+								 int be_verbose);
+extern	int	scg_close(SCSI * scgp);
+extern	void	scg_settimeout(SCSI * scgp, int timeout);
+extern	SCSI	*scg_smalloc(void);
+extern	void	scg_sfree(SCSI *scgp);
 
 /*
  * From scgsettarget.c:
  */
-extern	int	scg_settarget		__PR((SCSI *scgp, int scsibus, int target, int lun));
+extern	int	scg_settarget(SCSI *scgp, int scsibus, int target, int lun);
 
 /*
  * From scsi-remote.c:
  */
-extern	scg_ops_t *scg_remote	__PR((void));
+extern	scg_ops_t *scg_remote(void);
 
 /*
  * From scsihelp.c:
  */
 #ifdef	EOF	/* stdio.h has been included */
-extern	void	__scg_help	__PR((FILE *f, char *name, char *tcomment,
-					char *tind,
-					char *tspec,
-					char *texample,
-					BOOL mayscan,
-					BOOL bydev));
+extern	void	__scg_help(FILE *f, char *name, char *tcomment, char *tind,
+								  char *tspec, char *texample, BOOL mayscan, 
+								  BOOL bydev);
 #endif
 
 #ifdef	__cplusplus

Modified: nonameyet/branches/cleanup/libscg/scgsettarget.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scgsettarget.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scgsettarget.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -45,14 +45,10 @@
 
 #include <scg/scsitransp.h>
 
-EXPORT	int	scg_settarget	__PR((SCSI *scgp, int, int, int));
+int	scg_settarget(SCSI *scgp, int, int, int);
 
-EXPORT int
-scg_settarget(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+int
+scg_settarget(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	int fd = -1;
 

Modified: nonameyet/branches/cleanup/libscg/scgtimes.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scgtimes.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scgtimes.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -43,15 +43,14 @@
 #include <scg/scsitransp.h>
 #include "scgtimes.h"
 
-EXPORT	void	__scg_times	__PR((SCSI *scgp));
+void	__scg_times(SCSI *scgp);
 
 /*
  * We don't like to make this a public interface to prevent bad users
  * from making our timing incorrect.
  */
-EXPORT void
-__scg_times(scgp)
-	SCSI	*scgp;
+void
+__scg_times(SCSI *scgp)
 {
 	struct timeval	*stp = scgp->cmdstop;
 

Modified: nonameyet/branches/cleanup/libscg/scgtimes.h
===================================================================
--- nonameyet/branches/cleanup/libscg/scgtimes.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scgtimes.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -31,4 +31,4 @@
  * Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  */
 
-extern	void	__scg_times	__PR((SCSI *scgp));
+extern	void	__scg_times(SCSI *scgp);

Modified: nonameyet/branches/cleanup/libscg/scsi-aix.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-aix.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-aix.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -53,32 +53,30 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-aix.c-1.36";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-aix.c-1.36";	/* The version for this transport*/
 
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
 #define	MAX_LUN		8
 
-struct scg_local {
+struct scg_local{
 	short	scgfiles[MAX_SCG][MAX_TGT][MAX_LUN];
 };
-#define	scglocal(p)	((struct scg_local *)((p)->local))
+#define	scglocal(p)	((struct scg_local*)((p)->local))
 
 #define	MAX_DMA_AIX (64*1024)
 
-LOCAL	int	do_scg_cmd	__PR((SCSI *scgp, struct scg_cmd *sp));
-LOCAL	int	do_scg_sense	__PR((SCSI *scgp, struct scg_cmd *sp));
+static	int	do_scg_cmd(SCSI *scgp, struct scg_cmd *sp);
+static	int	do_scg_sense(SCSI *scgp, struct scg_cmd *sp);
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -98,20 +96,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "DKIOCMD", "SCSI transport for targets known by AIX drivers",
 		"", "bus,target,lun or UNIX device", "1,2,0 or /dev/rcd0@", FALSE, TRUE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -186,16 +180,15 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
 	register int	t;
 	register int	l;
 
-	if (scgp->local == NULL)
+	if (scgp->local== NULL)
 		return (-1);
 
 	for (b = 0; b < MAX_SCG; b++) {
@@ -211,20 +204,16 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA_AIX);
 }
 
 #define	palign(x, a)	(((char *)(x)) + ((a) - 1 - (((UIntptr_t)((x)-1))%(a))))
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	void	*ret;
 	int	pagesize;
@@ -249,19 +238,16 @@
 	return (ret);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -280,12 +266,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -298,24 +280,20 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -329,10 +307,8 @@
 	return (ioctl(scgp->fd, SCIORESET, IDLUN(scg_target(scgp), scg_lun(scgp))));
 }
 
-LOCAL int
-do_scg_cmd(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_cmd(SCSI *scgp, struct scg_cmd *sp)
 {
 	struct sc_iocmd req;
 	int	ret;
@@ -411,10 +387,8 @@
 	return (ret);
 }
 
-LOCAL int
-do_scg_sense(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_sense(SCSI *scgp, struct scg_cmd *sp)
 {
 	int		ret;
 	struct scg_cmd	s_cmd;
@@ -439,9 +413,8 @@
 	return (ret);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int	ret;

Modified: nonameyet/branches/cleanup/libscg/scsi-amigaos.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-amigaos.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-amigaos.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -63,60 +63,58 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-amigaos.c-1.6";	/* The version for this transport */
-LOCAL	char	_scg_auth[] = "T. Langer";
+static	char	_scg_trans_version[] = "scsi-amigaos.c-1.6";	/* The version for this transport */
+static	char	_scg_auth[] = "T. Langer";
 
 #define	MAX_SCG		8	/* Max # of SCSI controllers */
 #define	MAX_TGT		8
 #define	MAX_LUN		8
 #define	MAX_DEV		MAX_SCG*MAX_TGT*MAX_LUN
 
-struct scg_local {
+struct scg_local{
 	int	scgfiles[MAX_SCG][MAX_TGT][MAX_LUN];
 };
 
-#define	scglocal(p)	((struct scg_local *)((p)->local))
+#define	scglocal(p)	((struct scg_local*)((p)->local))
 
 #define	MAX_DMA_AMIGAOS (64*1024)
 
-LOCAL struct IOReq {
+static struct IOReq {
 	struct IOStdReq *ioReq;
 	int		ref_count;
 } request[MAX_DEV];
 
-LOCAL	char			*devs[MAX_SCG];
-LOCAL	struct MsgPort		*ioMsgPort = NULL;
-LOCAL	struct timerequest	*timer_io = NULL;
-LOCAL	struct MsgPort		*timerMsgPort = NULL;
-LOCAL	int			initialized = 0;
-LOCAL	int			last_bus = -1;
+static	char					*devs[MAX_SCG];
+static	struct MsgPort		*ioMsgPort = NULL;
+static	struct timerequest	*timer_io = NULL;
+static	struct MsgPort		*timerMsgPort = NULL;
+static	int			initialized = 0;
+static	int			last_bus = -1;
 /* my private var: for debug purpose only */
-LOCAL	int			ami_debug = 0;
+static	int			ami_debug = 0;
 
 extern	struct ExecBase		*SysBase;
 #define	IOERR_TIMEOUT		(-8)
 #define	CHECK_CONDITION		0x02
 #define	DUNIT(b, t, l)		(100 * b) + (10 * (l < 0 ? 0:l)) + t
 
-LOCAL	void	amiga_init		__PR((void));
-LOCAL	int	amiga_open_scsi		__PR((int bus, int tgt, int lun, SCSI *scgp));
-LOCAL	void	amiga_close_scsi	__PR((int fd));
-LOCAL	void	amiga_close_scsi_all	__PR((void));
-LOCAL	void	amiga_scan_devices	__PR((void));
-LOCAL	int	amiga_find_device	__PR((char *device));
-LOCAL	int	amiga_open_timer	__PR((void));
-LOCAL	void	amiga_close_timer	__PR((void));
-LOCAL	int	amiga_get_scsi_bus	__PR((char *device));
+static	void	amiga_init(void);
+static	int	amiga_open_scsi(int bus, int tgt, int lun, SCSI *scgp);
+static	void	amiga_close_scsi(int fd);
+static	void	amiga_close_scsi_all(void);
+static	void	amiga_scan_devices(void);
+static	int	amiga_find_device(char *device);
+static	int	amiga_open_timer(void);
+static	void	amiga_close_timer(void);
+static	int	amiga_get_scsi_bus(char *device);
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -137,20 +135,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "Amiga SCSI", "Generic SCSI",
 		"", "bus,target,lun or xxx.device:b,t,l", "1,2,0 or scsi.device:1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -258,9 +252,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int    b;
 	register int    t;
@@ -281,18 +274,14 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA_AMIGAOS);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -302,19 +291,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -333,12 +319,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -351,33 +333,28 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	/* XXX Is there really no reset function on AmigaOS? */
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	register struct IOStdReq *ioreq = NULL;
 	struct SCSICmd	Cmd;
@@ -467,10 +444,8 @@
 	return (ret);
 }
 
-LOCAL int
-do_scsi_cmd(scsi_io, timeout)
-	struct IOStdReq	*scsi_io;
-	int		timeout;
+static int
+do_scsi_cmd(struct IOStdReq *scsi_io, int timeout)
 {
 	ULONG	scsi_flag = 0;
 	ULONG	timer_flag = 0;
@@ -518,9 +493,8 @@
 /*--------------------------------------------------------------------------*/
 
 /* strlwr: seems not to be implemented in ixemul */
-LOCAL char *
-strlwr(s)
-	char *s;
+static char *
+strlwr(char *s)
 {
 	unsigned char *s1;
 
@@ -536,7 +510,7 @@
 /*
  * amiga specific functions
  */
-LOCAL void
+static void
 amiga_init()
 {
 	memset(request, 0, sizeof (request));
@@ -547,7 +521,7 @@
 	atexit(amiga_close_scsi_all);
 }
 
-LOCAL void
+static void
 amiga_scan_devices()
 {
 	/*
@@ -593,9 +567,8 @@
 	}
 }
 
-LOCAL void
-amiga_close_scsi(fd)
-	int	fd;
+static void
+amiga_close_scsi(int fd)
 {
 	if (request[fd].ref_count > 0) {
 		request[fd].ref_count--;
@@ -610,7 +583,7 @@
 	}
 }
 
-LOCAL void
+static void
 amiga_close_scsi_all()
 {
 	int	i;
@@ -637,12 +610,8 @@
 	}
 }
 
-LOCAL int
-amiga_open_scsi(bus, tgt, lun, scgp)
-	int	bus;
-	int	tgt;
-	int	lun;
-	SCSI	*scgp;
+static int
+amiga_open_scsi(int bus, int tgt, int lun, SCSI *scgp)
 {
 	int	fd = bus * MAX_TGT * MAX_LUN + tgt * MAX_LUN + lun;
 	int	unit = DUNIT(bus, tgt, lun);
@@ -699,7 +668,7 @@
 	return (fd);
 }
 
-LOCAL int
+static int
 amiga_open_timer()
 {
 	int	ret = 0;
@@ -738,7 +707,7 @@
 	return (ret);
 }
 
-LOCAL void
+static void
 amiga_close_timer()
 {
 	if (timer_io) {
@@ -755,9 +724,8 @@
 	}
 }
 
-LOCAL int
-amiga_get_scsi_bus(device)
-	char	*device;
+static int
+amiga_get_scsi_bus(char *device)
 {
 	int 	i;
 	char	*tmp = strdup(device);
@@ -778,9 +746,8 @@
 	return (-1);
 }
 
-LOCAL int
-amiga_find_device(device)
-	char	*device;
+static int
+amiga_find_device(char *device)
 {
 	char		tmp[256];
 	struct Node	*DeviceLibNode = SysBase->DeviceList.lh_Head;

Modified: nonameyet/branches/cleanup/libscg/scsi-apollo.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-apollo.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-apollo.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -48,7 +48,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-apollo.c-1.5";	/* The version for this transport */
+static	char	_scg_trans_version[] = "scsi-apollo.c-1.5";	/* The version for this transport */
 
 
 #define	MAX_SCG		1	/* Max # of SCSI controllers */
@@ -72,10 +72,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -95,20 +93,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "scsi_$do_command_2", "SCSI transport from Apollo DomainOS drivers",
 		"", "DomainOS driver name", "A DomainOS device node name", FALSE, TRUE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	register int	nopen = 0;
 	status_$t	status;
@@ -148,9 +142,8 @@
 	return (++nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	status_$t	status;
 
@@ -164,10 +157,8 @@
 }
 
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	status_$t	status;
 	scsi_$info_t	info;
@@ -184,10 +175,8 @@
 }
 
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	void	*ret;
 
@@ -200,9 +189,8 @@
 	return (ret);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->debug > 1)
 		printf("Entering scsi_freebuf\n");
@@ -212,10 +200,8 @@
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -237,12 +223,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (scgp->debug > 1)
 		printf("Entered scsi_fileno:  scgp=%p, busno=%d, tgt=%d, tlun=%d\n", scgp, busno, tgt, tlun);
@@ -258,9 +240,8 @@
 	return ((int) scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	if (scgp->debug > 1)
 		printf("Entering scsi_initiator\n");
@@ -268,17 +249,14 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	status_$t	status;
 
@@ -299,10 +277,8 @@
 	}
 }
 
-LOCAL void
-scsi_do_sense(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static void
+scsi_do_sense(SCSI *scgp, struct scg_cmd *sp)
 {
 	scsi_$op_status_t	op_status;
 	static scsi_$cdb_t	sense_cdb;
@@ -361,9 +337,8 @@
 }
 
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	linteger	buffer_length;
 	linteger	cdb_len;

Modified: nonameyet/branches/cleanup/libscg/scsi-beos.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-beos.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-beos.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -54,7 +54,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-beos.c-1.23";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-beos.c-1.23";	/* The version for this transport*/
 
 /*
  * There are also defines for:
@@ -160,10 +160,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -183,20 +181,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "CAM", "Generic transport independent SCSI (BeOS CAM variant)",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -225,9 +219,8 @@
 	return (1);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	struct _fdmap_	*f;
 	struct _fdmap_	*fnext;
@@ -241,19 +234,15 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (128*1024);
 	return (256*1024);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -263,19 +252,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	struct stat	sb;
 	char		buf[128];
@@ -289,12 +275,8 @@
 	return (TRUE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	struct _fdmap_	*f;
 	char		buf[128];
@@ -328,16 +310,14 @@
 	return (fd);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	/*
 	 * XXX Should check for ATAPI
@@ -345,18 +325,15 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI	*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd		*sp = scgp->scmd;
 	int			e;

Modified: nonameyet/branches/cleanup/libscg/scsi-bsd-os.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-bsd-os.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-bsd-os.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -63,7 +63,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-bsd-os.c-1.28";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-bsd-os.c-1.28";	/* The version for this transport*/
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -79,17 +79,15 @@
 #define	MAX_DMA_BSDI	MAXPHYS		/* More makes problems */
 
 
-LOCAL	BOOL	scg_setup	__PR((SCSI *scgp, int f, int busno, int tgt, int tlun));
+static	BOOL	scg_setup(SCSI *scgp, int f, int busno, int tgt, int tlun);
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -109,20 +107,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SCSIRAWCDB", "Generic SCSI for devices known by BSDi",
 		"", "devname:@,lun", "/dev/rsr0a:@,0", FALSE, TRUE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -226,9 +220,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -251,13 +244,8 @@
 	return (0);
 }
 
-LOCAL BOOL
-scg_setup(scgp, f, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	f;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static BOOL
+scg_setup(SCSI *scgp, int f, int busno, int tgt, int tlun)
 {
 	int	Bus;
 	int	Target;
@@ -298,20 +286,16 @@
 	return (FALSE);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = MAX_DMA_BSDI;
 
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -321,19 +305,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -352,12 +333,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -370,24 +347,20 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	/*
 	 * Cannot reset on BSD/OS
@@ -396,9 +369,8 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	scsi_user_cdb_t	suc;

Modified: nonameyet/branches/cleanup/libscg/scsi-bsd.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-bsd.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-bsd.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -59,7 +59,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-bsd.c-1.42";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-bsd.c-1.42";	/* The version for this transport*/
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -97,17 +97,15 @@
 #define	SADDR_LUN(a)	(a).lun
 #endif	/* __NetBSD__ && TYPE_ATAPI */
 
-LOCAL	BOOL	scg_setup	__PR((SCSI *scgp, int f, int busno, int tgt, int tlun));
+static	BOOL	scg_setup(SCSI *scgp, int f, int busno, int tgt, int tlun);
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -127,20 +125,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SCIOCCOMMAND", "SCSI for devices known by *BSD",
 		"", "device or bus,target,lun", "/dev/rcd0a:@ or 1,2,0", FALSE, TRUE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -253,9 +247,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -278,13 +271,8 @@
 	return (0);
 }
 
-LOCAL BOOL
-scg_setup(scgp, f, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	f;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static BOOL
+scg_setup(SCSI *scgp, int f, int busno, int tgt, int tlun)
 {
 	struct scsi_addr saddr;
 	int	Bus;
@@ -328,20 +316,16 @@
 	return (FALSE);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = MAX_DMA_BSD;
 
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -351,19 +335,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -382,12 +363,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -400,17 +377,14 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
-
+static int
+scgo_isatapi(SCSI *scgp)
 {
 #ifdef	MAYBE_ATAPI
 	struct scsi_addr saddr;
@@ -424,10 +398,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -441,9 +413,8 @@
 	return (ioctl(scgp->fd, SCIOCRESET, 0));
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	scsireq_t	req;
@@ -572,7 +543,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-bsd.c-1.42";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-bsd.c-1.42";	/* The version for this transport*/
 
 #define	CAM_MAXDEVS	128
 struct scg_local {
@@ -585,10 +556,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -608,10 +577,8 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "CAM", "Generic transport independent SCSI (Common Access Method)",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
@@ -621,10 +588,8 @@
 /*
  * Build a list of everything we can find.
  */
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int				busno	= scg_scsibus(scgp);
 	int				tgt	= scg_target(scgp);
@@ -807,9 +772,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	i;
 
@@ -824,10 +788,8 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 #ifdef	DFLTPHYS
 	return (DFLTPHYS);
@@ -836,10 +798,8 @@
 #endif
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -849,19 +809,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	int		unit;
 
@@ -881,12 +838,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, unit, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	unit;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int unit, int tlun)
 {
 	int		i;
 
@@ -904,33 +857,28 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	/* XXX synchronous reset command - is this wise? */
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI	*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd		*sp = scgp->scmd;
 	struct cam_device	*dev;

Modified: nonameyet/branches/cleanup/libscg/scsi-dos.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-dos.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-dos.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -62,7 +62,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-dos.c-1.11";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-dos.c-1.11";	/* The version for this transport*/
 
 #define	MAX_SCG	8
 #define	MAX_TGT	8
@@ -75,23 +75,21 @@
 
 #define	MAX_DMA_DOS	(63L*1024L)
 
-LOCAL	BYTE	busses		= 1;
-LOCAL	DWORD	SCSIMgrEntry	= 0;
-LOCAL	int	AspiLoaded	= 0;
+static	BYTE	busses		= 1;
+static	DWORD	SCSIMgrEntry	= 0;
+static	int	AspiLoaded	= 0;
 
-LOCAL	BOOL	_callback_flag;
-LOCAL	_go32_dpmi_seginfo _callback_info;
-LOCAL	_go32_dpmi_registers _callback_regs;
+static	BOOL	_callback_flag;
+static	_go32_dpmi_seginfo _callback_info;
+static	_go32_dpmi_registers _callback_regs;
 
-LOCAL	BOOL	SCSIMgrOpen	__PR((SCSI *));
-LOCAL	void	SCSIMgrClose	__PR((void));
-LOCAL	int 	SCSIMgrSendSRB	__PR((SRB *, time_t));
-LOCAL	void	SCSIMgrCallBack	__PR((_go32_dpmi_registers *regs));
+static	BOOL	SCSIMgrOpen(SCSI *);
+static	void	SCSIMgrClose(void);
+static	int 	SCSIMgrSendSRB(SRB *, time_t);
+static	void	SCSIMgrCallBack(_go32_dpmi_registers *regs);
 
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -107,20 +105,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "ASPI", "Generic transport independent SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -186,26 +180,21 @@
 	return (1);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	SCSIMgrClose();
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA_DOS);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -215,19 +204,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL __SBOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static __SBOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	if (busno < 0 || busno >= busses)
 		return (FALSE);
@@ -235,12 +221,8 @@
 	return (TRUE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= busses ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -253,32 +235,27 @@
 	return (1);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	SRB		Srb;
@@ -457,9 +434,8 @@
 	return (0);
 }
 
-LOCAL BOOL
-SCSIMgrOpen(scgp)
-	SCSI	*scgp;
+static BOOL
+SCSIMgrOpen(SCSI *scgp)
 {
 	int		hSCSIMgr;
 	int		dos_memory_seg;
@@ -530,7 +506,7 @@
 	return (TRUE);
 }
 
-LOCAL void
+static void
 SCSIMgrClose()
 {
 	if (--AspiLoaded > 0)
@@ -541,10 +517,8 @@
 	}
 }
 
-LOCAL int
-SCSIMgrSendSRB(Srb, timeout)
-	SRB	*Srb;
-	time_t	timeout;
+static int
+SCSIMgrSendSRB(SRB *Srb, time_t timeout)
 {
 	int		dos_memory_srb_seg;
 	int		dos_memory_srb_sel;
@@ -585,9 +559,8 @@
 	return (Srb->Status);
 }
 
-LOCAL void
-SCSIMgrCallBack(regs)
-	_go32_dpmi_registers	*regs;
+static void
+SCSIMgrCallBack(_go32_dpmi_registers *regs)
 {
 	_callback_flag = 1;
 }

Modified: nonameyet/branches/cleanup/libscg/scsi-hpux.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-hpux.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-hpux.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -51,7 +51,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-hpux.c-1.31";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-hpux.c-1.31";	/* The version for this transport*/
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -74,10 +74,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -97,20 +95,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SIOC", "Generic SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -183,9 +177,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -208,18 +201,14 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return	(MAX_DMA_HP);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -229,19 +218,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -260,12 +246,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -278,24 +260,20 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -306,9 +284,8 @@
 	return (ioctl(scgp->fd, SIOC_RESET_BUS, 0));
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int		ret;

Modified: nonameyet/branches/cleanup/libscg/scsi-linux-ata.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-linux-ata.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-linux-ata.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -57,21 +57,21 @@
 
 #ifdef	USE_ATA
 
-LOCAL	char	_scg_atrans_version[] = "scsi-linux-ata.c-1.7";	/* The version for ATAPI transport*/
+static	char	_scg_atrans_version[] = "scsi-linux-ata.c-1.7";	/* The version for ATAPI transport*/
 
-LOCAL	char *	scgo_aversion	__PR((SCSI *scgp, int what));
-LOCAL	int	scgo_ahelp	__PR((SCSI *scgp, FILE *f));
-LOCAL	int	scgo_aopen	__PR((SCSI *scgp, char *device));
-LOCAL	int	scgo_aclose	__PR((SCSI *scgp));
-LOCAL	long	scgo_amaxdma	__PR((SCSI *scgp, long amt));
-LOCAL	BOOL	scgo_ahavebus	__PR((SCSI *scgp, int));
-LOCAL	int	scgo_afileno	__PR((SCSI *scgp, int, int, int));
-LOCAL	int	scgo_ainitiator_id __PR((SCSI *scgp));
-LOCAL	int	scgo_aisatapi	__PR((SCSI *scgp));
-LOCAL	int	scgo_areset	__PR((SCSI *scgp, int what));
-LOCAL	int	scgo_asend	__PR((SCSI *scgp));
+static	char *scgo_aversion(SCSI *scgp, int what);
+static	int	scgo_ahelp(SCSI *scgp, FILE *f);
+static	int	scgo_aopen(SCSI *scgp, char *device);
+static	int	scgo_aclose(SCSI *scgp);
+static	long	scgo_amaxdma(SCSI *scgp, long amt);
+static	BOOL	scgo_ahavebus(SCSI *scgp, int);
+static	int	scgo_afileno(SCSI *scgp, int, int, int);
+static	int	scgo_ainitiator_id(SCSI *scgp);
+static	int	scgo_aisatapi(SCSI *scgp);
+static	int	scgo_areset(SCSI *scgp, int what);
+static	int	scgo_asend(SCSI *scgp);
 
-LOCAL scg_ops_t ata_ops = {
+static scg_ops_t ata_ops = {
 	scgo_asend,
 	scgo_aversion,
 	scgo_ahelp,
@@ -103,15 +103,14 @@
 #define	MAX_DMA_ATA (131072-1)	/* EINVAL (hart) ENOMEM (weich) bei mehr ... */
 				/* Bei fehlerhaftem Sense Pointer kommt EFAULT */
 
-LOCAL int scgo_send		__PR((SCSI * scgp));
-LOCAL BOOL sg_amapdev		__PR((SCSI * scgp, int f, char *device, int *bus,
-					int *target, int *lun));
-LOCAL BOOL sg_amapdev_scsi	__PR((SCSI * scgp, int f, int *busp, int *tgtp,
-					int *lunp, int *chanp, int *inop));
-LOCAL int scgo_aget_first_free_shillybus __PR((SCSI * scgp, int subsystem,
-					int host, int bus));
-LOCAL int scgo_amerge		__PR((char *path, char *readedlink,
-					char *buffer, int buflen));
+static int scgo_send(SCSI * scgp);
+static BOOL sg_amapdev(SCSI * scgp, int f, char *device, int *bus, 
+							  int *target, int *lun);
+static BOOL sg_amapdev_scsi(SCSI * scgp, int f, int *busp, int *tgtp,
+									 int *lunp, int *chanp, int *inop);
+static int scgo_aget_first_free_shillybus(SCSI * scgp, int subsystem,
+														int host, int bus);
+static int scgo_amerge(char *path, char *readedlink, char *buffer, int buflen);
 
 /*
  * uncomment this when you will get a debug file #define DEBUG
@@ -120,20 +119,13 @@
 #define	LOGFILE "scsi-linux-ata.log"
 #define	log(a)	sglog a
 
-LOCAL	void	sglog		__PR((const char *fmt, ...));
+static	void	sglog(const char *fmt, ...);
 
 #include <vadefs.h>
 
 /* VARARGS1 */
-#ifdef	PROTOTYPES
-LOCAL void
+static void
 sglog(const char *fmt, ...)
-#else
-LOCAL void
-error(fmt, va_alist)
-	char	*fmt;
-	va_dcl
-#endif
 {
 	va_list	args;
 	FILE	*f	 = fopen(LOGFILE, "a");
@@ -141,11 +133,7 @@
 	if (f == NULL)
 		return;
 
-#ifdef	PROTOTYPES
 	va_start(args, fmt);
-#else
-	va_start(args);
-#endif
 	js_fprintf(f, "%r", fmt, args);
 	va_end(args);
 	fclose(f);
@@ -154,17 +142,15 @@
 #define	log(a)
 #endif	/* DEBUG */
 
-LOCAL	int	scan_internal __PR((SCSI * scgp, int *fatal));
+static	int	scan_internal(SCSI * scgp, int *fatal);
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_aversion(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_aversion(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -184,20 +170,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_ahelp(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_ahelp(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "ATA", "ATA Packet specific SCSI transport",
 		"ATAPI:", "bus,target,lun", "ATAPI:1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_aopen(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_aopen(SCSI *scgp, char *device)
 {
 	int	bus = scg_scsibus(scgp);
 	int	target = scg_target(scgp);
@@ -294,10 +276,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scan_internal(scgp, nopen)
-	SCSI	*scgp;
-	int	*nopen;
+static int
+scan_internal(SCSI *scgp, int *nopen)
 {
 	int	i,
 		f;
@@ -419,9 +399,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_aclose(scgp)
-	SCSI	*scgp;
+static int
+scgo_aclose(SCSI *scgp)
 {
 	register int	f;
 	register int	h;
@@ -452,12 +431,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_aget_first_free_shillybus(scgp, subsystem, host, bus)
-	SCSI	*scgp;
-	int	subsystem;
-	int	host;
-	int	bus;
+static int
+scgo_aget_first_free_shillybus(SCSI *scgp, int subsystem, int host, int bus)
 {
 	int	first_free_schilly_bus;
 
@@ -481,12 +456,8 @@
 	return (first_free_schilly_bus);
 }
 
-LOCAL int
-scgo_amerge(path, readedlink, buffer, buflen)
-	char	*path;
-	char	*readedlink;
-	char	*buffer;
-	int	buflen;
+static int
+scgo_amerge(char *path, char *readedlink, char *buffer, int buflen)
 {
 	char	*aa;
 
@@ -623,14 +594,9 @@
  *	Example /dev/cdroms/cdrom1 ->  /dev/ide/host1/bus0/target1/lun4/cd
  *
  */
-LOCAL BOOL
-sg_amapdev(scgp, f, device, schillybus, target, lun)
-	SCSI	*scgp;
-	int	f;
-	char	*device;
-	int	*schillybus;
-	int	*target;
-	int	*lun;
+static BOOL
+sg_amapdev(SCSI *scgp, int f, char *device, int *schillybus, int *target, 
+			  int *lun)
 {
 	struct host {
 		char	host[4];
@@ -880,15 +846,9 @@
 	return (TRUE);
 }
 
-LOCAL BOOL
-sg_amapdev_scsi(scgp, f, busp, tgtp, lunp, chanp, inop)
-	SCSI	*scgp;
-	int	f;
-	int	*busp;
-	int	*tgtp;
-	int	*lunp;
-	int	*chanp;
-	int	*inop;
+static BOOL
+sg_amapdev_scsi(SCSI *scgp, int f, int *busp, int *tgtp, int *lunp, 
+					 int *chanp, int *inop)
 {
 	struct sg_id {
 		long	l1;	/* target | lun << 8 | channel << 16 | low_ino << 24 */
@@ -929,10 +889,8 @@
 	return (TRUE);
 }
 
-LOCAL long
-scgo_amaxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_amaxdma(SCSI *scgp, long amt)
 {
 	/*
 	 * EINVAL (hart) ENOMEM (weich) bei mehr ...
@@ -941,10 +899,8 @@
 	return (MAX_DMA_ATA);
 }
 
-LOCAL BOOL
-scgo_ahavebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_ahavebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -963,12 +919,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_afileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_afileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCHILLY_HOSTS ||
 		tgt < 0 || tgt >= MAX_TGT ||
@@ -981,17 +933,15 @@
 	return ((int) scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_ainitiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_ainitiator_id(SCSI *scgp)
 {
 	js_printf(scgp->errstr, "NOT IMPELEMENTED: scgo_initiator_id");
 	return (-1);
 }
 
-LOCAL int
-scgo_aisatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_aisatapi(SCSI *scgp)
 {
 	int schillybus = scgp->addr.scsibus;
 	int typ = typlocal(scgp, schillybus);
@@ -1003,10 +953,8 @@
 		return (0);
 }
 
-LOCAL int
-scgo_areset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_areset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -1017,9 +965,8 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_asend(scgp)
-	SCSI	*scgp;
+static int
+scgo_asend(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int		ret,

Modified: nonameyet/branches/cleanup/libscg/scsi-linux-pg.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-linux-pg.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-linux-pg.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -59,7 +59,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version_pg[] = "scsi-linux-pg.c-1.43";	/* The version for this transport*/
+static	char	_scg_trans_version_pg[] = "scsi-linux-pg.c-1.43";	/* The version for this transport*/
 
 #ifdef	USE_PG_ONLY
 
@@ -87,20 +87,20 @@
 #define	scgo_isatapi	pg_isatapi
 #define	scgo_reset	pg_reset
 
-LOCAL	char	*pg_version	__PR((SCSI *scgp, int what));
-LOCAL	int	pg_help		__PR((SCSI *scgp, FILE *f));
-LOCAL	int	pg_open		__PR((SCSI *scgp, char *device));
-LOCAL	int	pg_close	__PR((SCSI *scgp));
-LOCAL	long	pg_maxdma	__PR((SCSI *scgp, long amt));
-LOCAL	int 	pg_initiator_id	__PR((SCSI *scgp));
-LOCAL	int 	pg_isatapi	__PR((SCSI *scgp));
-LOCAL	int	pg_reset	__PR((SCSI *scgp, int what));
-LOCAL	int	pg_send		__PR((SCSI *scgp));
+static	char	*pg_version(SCSI *scgp, int what);
+static	int	pg_help(SCSI *scgp, FILE *f);
+static	int	pg_open(SCSI *scgp, char *device);
+static	int	pg_close(SCSI *scgp);
+static	long	pg_maxdma(SCSI *scgp, long amt);
+static	int 	pg_initiator_id(SCSI *scgp);
+static	int 	pg_isatapi(SCSI *scgp);
+static	int	pg_reset(SCSI *scgp, int what);
+static	int	pg_send(SCSI *scgp);
 
 #endif
 
-LOCAL	int	do_scg_cmd	__PR((SCSI *scgp, struct scg_cmd *sp));
-LOCAL	int	do_scg_sense	__PR((SCSI *scgp, struct scg_cmd *sp));
+static	int	do_scg_cmd(SCSI *scgp, struct scg_cmd *sp);
+static	int	do_scg_sense(SCSI *scgp, struct scg_cmd *sp);
 
 
 /*
@@ -108,10 +108,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -131,20 +129,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "pg", "SCSI transport for ATAPI over Parallel Port",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -283,9 +277,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -310,20 +303,16 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (PG_MAX_DATA);
 }
 
 #ifdef	USE_PG_ONLY
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	char    *ret;
 
@@ -341,19 +330,16 @@
 
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -372,12 +358,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -391,24 +373,20 @@
 }
 #endif	/* USE_PG_ONLY */
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (TRUE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	struct pg_write_hdr hdr = {PG_MAGIC, PG_RESET, 0};
 
@@ -433,10 +411,8 @@
 #define	WHSIZE  sizeof (struct pg_write_hdr)
 #define	LEAD	MAX(RHSIZE, WHSIZE)
 
-LOCAL int
-do_scg_cmd(scgp, sp)
-	SCSI	*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_cmd(SCSI *scgp, struct scg_cmd *sp)
 {
 
 	char	local[LEAD+PG_MAX_DATA];
@@ -556,10 +532,8 @@
 
 }
 
-LOCAL int
-do_scg_sense(scgp, sp)
-	SCSI	*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_sense(SCSI *scgp, struct scg_cmd *sp)
 {
 	int		ret;
 	struct scg_cmd 	s_cmd;
@@ -582,9 +556,8 @@
 	return (ret);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int	ret;

Modified: nonameyet/branches/cleanup/libscg/scsi-linux-sg.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-linux-sg.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-linux-sg.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -119,7 +119,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-linux-sg.c-1.86";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-linux-sg.c-1.86";	/* The version for this transport*/
 
 #ifndef	SCSI_IOCTL_GET_BUS_NUMBER
 #define	SCSI_IOCTL_GET_BUS_NUMBER 0x5386
@@ -225,30 +225,28 @@
 
 
 #ifdef	MISALIGN
-LOCAL	int	sg_getint	__PR((int *ip));
+static	int	sg_getint(int *ip);
 #endif
-LOCAL	int	scgo_send	__PR((SCSI *scgp));
+static	int	scgo_send(SCSI *scgp);
 #ifdef	SG_IO
-LOCAL	int	sg_rwsend	__PR((SCSI *scgp));
+static	int	sg_rwsend(SCSI *scgp);
 #endif
-LOCAL	void	sg_clearnblock	__PR((int f));
-LOCAL	BOOL	sg_setup	__PR((SCSI *scgp, int f, int busno, int tgt, int tlun, int ataidx));
-LOCAL	void	sg_initdev	__PR((SCSI *scgp, int f));
-LOCAL	int	sg_mapbus	__PR((SCSI *scgp, int busno, int ino));
-LOCAL	BOOL	sg_mapdev	__PR((SCSI *scgp, int f, int *busp, int *tgtp, int *lunp,
-							int *chanp, int *inop, int ataidx));
+static	void	sg_clearnblock(int f);
+static	BOOL	sg_setup(SCSI *scgp, int f, int busno, int tgt, int tlun, 
+								int ataidx);
+static	void	sg_initdev(SCSI *scgp, int f);
+static	int	sg_mapbus(SCSI *scgp, int busno, int ino);
+static	BOOL	sg_mapdev(SCSI *scgp, int f, int *busp, int *tgtp, int *lunp,
+								 int *chanp, int *inop, int ataidx);
 #if defined(SG_SET_RESERVED_SIZE) && defined(SG_GET_RESERVED_SIZE)
-LOCAL	long	sg_raisedma	__PR((SCSI *scgp, long newmax));
+static	long	sg_raisedma(SCSI *scgp, long newmax);
 #endif
-LOCAL	void	sg_settimeout	__PR((int f, int timeout));
+static	void	sg_settimeout(int f, int timeout);
 
-int    sg_open_excl    __PR((char *device, int mode, int quickAndQuiet));
+int    sg_open_excl(char *device, int mode, int quickAndQuiet);
 
 int
-sg_open_excl(device, mode, quickAndQuiet)
-       char    *device;
-       int     mode;
-       int quickAndQuiet;
+sg_open_excl(char *device, int mode, int quickAndQuiet)
 {
        int f;
        int i;
@@ -271,10 +269,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 #ifdef	USE_PG
@@ -318,10 +314,8 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "sg", "Generic transport independent SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
@@ -336,10 +330,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -630,9 +622,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -674,9 +665,8 @@
  * of the drivers requires O_NONBLOCK to be set during open().
  * This is used to clear O_NONBLOCK immediately after open() succeeded.
  */
-LOCAL void
-sg_clearnblock(f)
-	int	f;
+static void
+sg_clearnblock(int f)
 {
 	int	n;
 
@@ -685,14 +675,8 @@
 	fcntl(f, F_SETFL, n);
 }
 
-LOCAL BOOL
-sg_setup(scgp, f, busno, tgt, tlun, ataidx)
-	SCSI	*scgp;
-	int	f;
-	int	busno;
-	int	tgt;
-	int	tlun;
-	int	ataidx;
+static BOOL
+sg_setup(SCSI *scgp, int f, int busno, int tgt, int tlun, int ataidx)
 {
 	int	n;
 	int	Chan;
@@ -763,10 +747,8 @@
 	return (FALSE);
 }
 
-LOCAL void
-sg_initdev(scgp, f)
-	SCSI	*scgp;
-	int	f;
+static void
+sg_initdev(SCSI *scgp, int f)
 {
 	struct sg_rep {
 		struct sg_header	hd;
@@ -819,11 +801,8 @@
 	fcntl(f, F_SETFL, n);
 }
 
-LOCAL int
-sg_mapbus(scgp, busno, ino)
-	SCSI	*scgp;
-	int	busno;
-	int	ino;
+static int
+sg_mapbus(SCSI *scgp, int busno, int ino)
 {
 	register int	i;
 
@@ -855,16 +834,9 @@
 	return (0);
 }
 
-LOCAL BOOL
-sg_mapdev(scgp, f, busp, tgtp, lunp, chanp, inop, ataidx)
-	SCSI	*scgp;
-	int	f;
-	int	*busp;
-	int	*tgtp;
-	int	*lunp;
-	int	*chanp;
-	int	*inop;
-	int	ataidx;
+static BOOL
+sg_mapdev(SCSI *scgp, int f, int *busp, int *tgtp, int *lunp, int *chanp, 
+			 int *inop, int ataidx)
 {
 	struct	sg_id {
 		long	l1; /* target | lun << 8 | channel << 16 | low_ino << 24 */
@@ -931,10 +903,8 @@
  * on whether the request did fail. The only way to find if it worked
  * is to use SG_GET_RESERVED_SIZE to read back the current values.
  */
-LOCAL long
-sg_raisedma(scgp, newmax)
-	SCSI	*scgp;
-	long	newmax;
+static long
+sg_raisedma(SCSI *scgp, long newmax)
 {
 	register int	b;
 	register int	t;
@@ -1010,10 +980,8 @@
 }
 #endif
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = MAX_DMA_LINUX;
 
@@ -1052,10 +1020,8 @@
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	char	*ret;
 
@@ -1078,19 +1044,16 @@
 	return ((void *)ret);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -1109,12 +1072,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -1127,9 +1086,8 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 #ifdef	USE_PG
 	if (scg_scsibus(scgp) == scglocal(scgp)->pgbus)
@@ -1138,9 +1096,8 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 #ifdef	USE_PG
 	if (scg_scsibus(scgp) == scglocal(scgp)->pgbus)
@@ -1170,10 +1127,8 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 #ifdef	SG_SCSI_RESET
 	int	f = scgp->fd;
@@ -1215,10 +1170,8 @@
 	return (-1);
 }
 
-LOCAL void
-sg_settimeout(f, tmo)
-	int	f;
-	int	tmo;
+static void
+sg_settimeout(int f, int tmo)
 {
 	tmo *= HZ;
 	if (tmo)
@@ -1235,9 +1188,8 @@
  * reads of integers.
  */
 #ifdef	MISALIGN
-LOCAL int
-sg_getint(ip)
-	int	*ip;
+static int
+sg_getint(int *ip)
 {
 		int	ret;
 	register char	*cp = (char *)ip;
@@ -1255,9 +1207,8 @@
 #endif
 
 #ifdef	SG_IO
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int		ret;
@@ -1416,9 +1367,8 @@
 #	define	sg_rwsend	scgo_send
 #endif
 
-LOCAL int
-sg_rwsend(scgp)
-	SCSI		*scgp;
+static int
+sg_rwsend(SCSI *scgp)
 {
 	int		f = scgp->fd;
 	struct scg_cmd	*sp = scgp->scmd;

Modified: nonameyet/branches/cleanup/libscg/scsi-mac-iokit.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-mac-iokit.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-mac-iokit.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -55,7 +55,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-mac-iokit.c-1.10";	/* The version for this transport */
+static	char	_scg_trans_version[] = "scsi-mac-iokit.c-1.10";	/* The version for this transport */
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -86,10 +86,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -109,10 +107,8 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SCSITaskDeviceInterface", "Apple SCSI",
 		"", "Mac Prom device name", "IOCompactDiscServices/0",
@@ -131,10 +127,8 @@
  * more than the first device (e.g. IOCompactDiscServices/5 for the 5th
  * compact disc attached)
  */
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	mach_port_t masterPort = NULL;
 	io_iterator_t scsiObjectIterator = NULL;
@@ -327,9 +321,8 @@
 	return (err);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	SCSITaskDeviceInterface	**sc;
 	MMCDeviceInterface	**mmc;
@@ -354,10 +347,8 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = MAX_DMA_NEXT;
 #ifdef	SGIOCMAXDMA
@@ -374,10 +365,8 @@
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -387,54 +376,42 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	if (busno == 0)
 		return (TRUE);
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
-
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -447,9 +424,8 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd		*sp = scgp->scmd;
 	SCSITaskDeviceInterface	**sc = NULL;

Modified: nonameyet/branches/cleanup/libscg/scsi-next.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-next.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-next.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -53,7 +53,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-next.c-1.32";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-next.c-1.32";	/* The version for this transport*/
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -73,18 +73,15 @@
 #define	MAX_DMA_NEXT	(64*1024)	/* Check if this is not too big */
 
 
-LOCAL	BOOL	scg_setup	__PR((SCSI *scgp, int busno, int tgt, int tlun,
-								BOOL ex));
+static	BOOL	scg_setup(SCSI *scgp, int busno, int tgt, int tlun, BOOL ex);
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -104,20 +101,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SGIOCREQ", "Generic SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -194,9 +187,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	if (scgp->local == NULL)
 		return (-1);
@@ -207,13 +199,8 @@
 	return (0);
 }
 
-LOCAL BOOL
-scg_setup(scgp, busno, tgt, tlun, ex)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
-	BOOL	ex;
+static BOOL
+scg_setup(SCSI *scgp, int busno, int tgt, int tlun, BOOL ex)
 {
 	scsi_adr_t sadr;
 
@@ -253,10 +240,8 @@
 	return (TRUE);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = MAX_DMA_NEXT;
 #ifdef	SGIOCMAXDMA
@@ -282,10 +267,8 @@
 #define	SGIOCNUMTARGS	_IOR('s', 9, int)		/* # of targets/bus */
 #endif
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -295,19 +278,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	if (busno < 0 || busno >= MAX_SCG)
 		return (FALSE);
@@ -321,12 +301,8 @@
 	return (scg_setup(scgp, busno, 0, 0, FALSE));
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -345,25 +321,20 @@
 	return (scglocal(scgp)->scgfile);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
-
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -374,9 +345,8 @@
 	return (ioctl(scgp->fd, SGIOCRST, 0));
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	struct scsi_req	req;

Modified: nonameyet/branches/cleanup/libscg/scsi-openserver.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-openserver.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-openserver.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -52,7 +52,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-openserver.c-1.31";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-openserver.c-1.31";	/* The version for this transport*/
 
 #define	MAX_SCG		16		/* Max # of cdrom devices */
 #define	MAX_TGT		16		/* Not really needed	  */
@@ -114,10 +114,10 @@
 #define	DMA_OVERRIDE	"LIBSCG_MAX_DMA"	/* override MAX_DMA value */
 #define	ENABLE_USB	"LIBSCG_ENABLE_USB"	/* enable access of USB devices */
 
-LOCAL	int	scan_all	= 0;	/* don't scan all devices by default */
-LOCAL	int	scsiusercmd	= 0;	/* use SCSIUSERCMD2 ioctl by default */
-LOCAL	int	enable_usb	= 0;	/* don't scan USB devices by default */
-LOCAL	long	max_dma		= MAX_DMA; /* use MAX_DMA DMA buffer by default */
+static	int	scan_all	= 0;	/* don't scan all devices by default */
+static	int	scsiusercmd	= 0;	/* use SCSIUSERCMD2 ioctl by default */
+static	int	enable_usb	= 0;	/* don't scan USB devices by default */
+static	long	max_dma		= MAX_DMA; /* use MAX_DMA DMA buffer by default */
 
 
 /*
@@ -155,7 +155,7 @@
 
 } scg2sdi_t;
 
-LOCAL	scg2sdi_t	sdidevs [MAX_SCG][MAX_TGT][MAX_LUN];
+static	scg2sdi_t	sdidevs [MAX_SCG][MAX_TGT][MAX_LUN];
 
 typedef struct amscsi {
 	char	typ[MAXDRVN];
@@ -174,10 +174,10 @@
 };
 #define	scglocal(p)	((struct scg_local *)((p)->local))
 
-LOCAL	int	sort_mscsi	__PR((const void *l1, const void *l2));
-LOCAL	int	openserver_init	__PR((SCSI *scgp));
-LOCAL	void	cp_scg2sco	__PR((struct scsicmd2 *sco, struct scg_cmd *scg));
-LOCAL	void	cp_sco2scg	__PR((struct scsicmd2 *sco, struct scg_cmd *scg));
+static	int	sort_mscsi(const void *l1, const void *l2);
+static	int	openserver_init(SCSI *scgp);
+static	void	cp_scg2sco(struct scsicmd2 *sco, struct scg_cmd *scg);
+static	void	cp_sco2scg(struct scsicmd2 *sco, struct scg_cmd *scg);
 
 /*
  * -------------------------------------------------------------------------
@@ -211,10 +211,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -234,10 +232,8 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SCSIUSERCMD/SCSIUSERCMD2", "Generic SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
@@ -257,10 +253,8 @@
  */
 
 
-LOCAL int
-sort_mscsi(l1, l2)
-	const void	*l1;
-	const void	*l2;
+static int
+sort_mscsi(const void *l1, const void *l2)
 {
 	amscsi_t	*t1 = (amscsi_t *) l1;
 	amscsi_t	*t2 = (amscsi_t *) l2;
@@ -310,9 +304,8 @@
  *
  */
 
-LOCAL int
-openserver_init(scgp)
-	SCSI	*scgp;
+static int
+openserver_init(SCSI *scgp)
 {
 	FILE		*cmd;
 	int		nscg  = -1, lhba  = -1, lbus = -1;
@@ -681,10 +674,8 @@
 }
 
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -727,9 +718,8 @@
 
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -758,19 +748,15 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (max_dma);
 }
 
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -781,19 +767,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -812,12 +795,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt   < 0 || tgt   >= MAX_TGT ||
@@ -830,9 +809,8 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 
@@ -850,26 +828,21 @@
 	 */
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (sdidevs[scg_scsibus(scgp)][scg_target(scgp)][scg_lun(scgp)].atapi);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);		/* no scsi reset available */
 }
 
-LOCAL void
-cp_scg2sco(sco, scg)
-	struct scsicmd2	*sco;
-	struct scg_cmd	*scg;
+static void
+cp_scg2sco(struct scsicmd2 *sco, struct scg_cmd *scg)
 {
 	sco->cmd.data_ptr = (char *) scg->addr;
 	sco->cmd.data_len = scg->size;
@@ -892,10 +865,8 @@
 }
 
 
-LOCAL void
-cp_sco2scg(sco, scg)
-	struct scsicmd2	*sco;
-	struct scg_cmd	*scg;
+static void
+cp_sco2scg(struct scsicmd2 *sco, struct scg_cmd *scg)
 {
 	scg->size	= sco->cmd.data_len;
 
@@ -913,9 +884,8 @@
 }
 
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	struct scsicmd2	scsi_cmd;

Modified: nonameyet/branches/cleanup/libscg/scsi-os2.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-os2.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-os2.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -60,7 +60,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-os2.c-1.25";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-os2.c-1.25";	/* The version for this transport*/
 
 #define	FILE_OPEN			0x0001
 #define	OPEN_SHARE_DENYREADWRITE	0x0010
@@ -91,19 +91,19 @@
 
 #define	MAX_DMA_OS2	(63*1024) /* ASPI-Router allows up to 64k */
 
-LOCAL	void	*buffer		= NULL;
-LOCAL	HFILE	driver_handle	= 0;
-LOCAL	HEV	postSema	= 0;
+static	void	*buffer		= NULL;
+static	HFILE	driver_handle	= 0;
+static	HEV	postSema	= 0;
 
-LOCAL	BOOL	open_driver	__PR((SCSI *scgp));
-LOCAL	BOOL	close_driver	__PR((void));
-LOCAL	ULONG	wait_post	__PR((ULONG ulTimeOut));
-LOCAL	BOOL 	init_buffer	__PR((void* mem));
-LOCAL	void	exit_func	__PR((void));
-LOCAL	void	set_error	__PR((SRB *srb, struct scg_cmd *sp));
+static	BOOL	open_driver(SCSI *scgp);
+static	BOOL	close_driver(void);
+static	ULONG	wait_post(ULONG ulTimeOut);
+static	BOOL 	init_buffer(void* mem);
+static	void	exit_func(void);
+static	void	set_error(SRB *srb, struct scg_cmd *sp);
 
 
-LOCAL void
+static void
 exit_func()
 {
 	if (!close_driver())
@@ -115,10 +115,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -138,20 +136,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "ASPI", "Generic transport independent SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -190,27 +184,22 @@
 	return (1);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	exit_func();
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *cgp, long amt)
 {
 	long maxdma = MAX_DMA_OS2;
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	ULONG rc;
 
@@ -237,9 +226,8 @@
 	return ((void *)0); /* Error */
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase && DosFreeMem(scgp->bufbase)) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -250,10 +238,8 @@
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -264,12 +250,8 @@
 	return (TRUE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -283,25 +265,21 @@
 }
 
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	ULONG	rc;				/* return value */
 	ULONG	cbreturn;
@@ -350,10 +328,8 @@
 /*
  * Set error flags
  */
-LOCAL void
-set_error(srb, sp)
-	SRB	*srb;
-	struct scg_cmd	*sp;
+static void
+set_error(SRB *srb, struct scg_cmd *sp)
 {
 	switch (srb->status) {
 
@@ -377,9 +353,8 @@
 	}
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI	*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	ULONG	rc;				/* return value */
@@ -544,9 +519,8 @@
  *  Preconditions: ASPI Router driver has be loaded			   *
  *									   *
  ***************************************************************************/
-LOCAL BOOL
-open_driver(scgp)
-	SCSI	*scgp;
+static BOOL
+open_driver(SCSI *scgp)
 {
 	ULONG	rc;			/* return value */
 	ULONG	ActionTaken;		/* return value	*/
@@ -606,7 +580,7 @@
  *  Preconditions: ASPI Router driver has be opened with open_driver	   *
  *									   *
  ***************************************************************************/
-LOCAL BOOL
+static BOOL
 close_driver()
 {
 	ULONG rc;				/* return value */
@@ -627,7 +601,7 @@
 	return (TRUE);
 }
 
-LOCAL ULONG
+static ULONG
 wait_post(ULONG ulTimeOut)
 {
 	ULONG count = 0;
@@ -639,9 +613,8 @@
 	return (rc);
 }
 
-LOCAL BOOL
-init_buffer(mem)
-	void	*mem;
+static BOOL
+init_buffer(void *mem)
 {
 	ULONG	rc;					/* return value */
 	USHORT lockSegmentReturn;			/* return value */

Modified: nonameyet/branches/cleanup/libscg/scsi-osf.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-osf.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-osf.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -57,7 +57,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-osf.c-1.26";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-osf.c-1.26";	/* The version for this transport*/
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -69,7 +69,7 @@
 };
 #define	scglocal(p)	((struct scg_local *)((p)->local))
 
-LOCAL	BOOL	scsi_checktgt	__PR((SCSI *scgp, int f, int busno, int tgt, int tlun));
+static	BOOL	scsi_checktgt(SCSI *scgp, int f, int busno, int tgt, int tlun);
 
 /*
  * I don't have any documentation about CAM
@@ -85,10 +85,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -108,20 +106,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "CAM", "Generic transport independent SCSI (Common Access Method)",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -198,9 +192,8 @@
 	return (1);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	if (scgp->local == NULL)
 		return (-1);
@@ -216,13 +209,8 @@
  * OS is considering this target to be valid.
  * XXX Is this really needed? We should rather let the cmd fail later.
  */
-LOCAL BOOL
-scsi_checktgt(scgp, f, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	f;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static BOOL
+scsi_checktgt(SCSI *scgp, int f, int busno, int tgt, int tlun)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	struct scg_cmd	sc;
@@ -257,20 +245,16 @@
 }
 
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = MAX_DMA_OSF_CAM;
 
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -280,19 +264,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 
@@ -310,12 +291,8 @@
 }
 
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (scgp->local == NULL)
 		return (-1);
@@ -323,32 +300,27 @@
 	return ((busno < 0 || busno >= MAX_SCG) ? -1 : scglocal(scgp)->scgfile);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	CCB_SCSIIO	ccb;

Modified: nonameyet/branches/cleanup/libscg/scsi-qnx.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-qnx.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-qnx.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -55,7 +55,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-qnx.c-1.3";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-qnx.c-1.3";	/* The version for this transport*/
 
 #define	MAX_SCG		16	/* Max # of SCSI controllers */
 #define	MAX_TGT		16
@@ -77,10 +77,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -101,20 +99,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "CAM", "Generic transport independent SCSI (Common Access Method)",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int fd;
 
@@ -148,9 +142,8 @@
 	return (1);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	if (scgp->local == NULL)
 		return (-1);
@@ -161,20 +154,16 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long maxdma = QNX_CAM_MAX_DMA;
 
 	return (maxdma);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	void	*addr;
 
@@ -191,30 +180,23 @@
 	return (addr);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		munmap(scgp->bufbase, QNX_CAM_MAX_DMA);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	return (FALSE);
 }
 
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (scgp->local == NULL)
 		return (-1);
@@ -222,16 +204,14 @@
 	return ((busno < 0 || busno >= MAX_SCG) ? -1 : scglocal(scgp)->fd);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	cam_devinfo_t	cinfo;
 
@@ -241,18 +221,15 @@
 	return ((cinfo.flags & DEV_ATAPI) ? TRUE : FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	int		i;
 	struct scg_cmd	*sp;

Modified: nonameyet/branches/cleanup/libscg/scsi-sgi.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-sgi.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-sgi.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -56,7 +56,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-sgi.c-1.36";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-sgi.c-1.36";	/* The version for this transport*/
 
 #ifdef	USE_DSLIB
 
@@ -80,7 +80,7 @@
 
 
 #ifndef	USE_DSLIB
-LOCAL	int	scg_sendreq	__PR((SCSI *scgp, struct scg_cmd *sp, struct dsreq *dsp));
+static	int	scg_sendreq(SCSI *scgp, struct scg_cmd *sp, struct dsreq *dsp);
 #endif
 
 
@@ -89,10 +89,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -112,20 +110,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "DS", "Generic SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -210,9 +204,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 #ifndef	USE_DSLIB
 	register int	f;
@@ -239,18 +232,14 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA_SGI);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -260,19 +249,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -291,12 +277,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 #ifdef	USE_DSLIB
 	if (dsp == NULL)
@@ -315,24 +297,20 @@
 #endif
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	/*
 	 * Do we have a SCSI reset on SGI?
@@ -354,11 +332,8 @@
 }
 
 #ifndef	USE_DSLIB
-LOCAL int
-scg_sendreq(scgp, sp, dsp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
-	struct dsreq	*dsp;
+static int
+scg_sendreq(SCSI *scgp, struct scg_cmd *sp, struct dsreq *dsp)
 {
 	int	ret;
 	int	retries = 4;
@@ -416,9 +391,8 @@
 }
 #endif
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int	ret;

Modified: nonameyet/branches/cleanup/libscg/scsi-sun.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-sun.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-sun.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -71,29 +71,29 @@
 #	define	USE_USCSI
 #endif
 
-LOCAL	char	_scg_trans_version[] = "scg-1.83";	/* The version for /dev/scg	*/
-LOCAL	char	_scg_utrans_version[] = "uscsi-1.83";	/* The version for USCSI	*/
+static	char	_scg_trans_version[] = "scg-1.83";	/* The version for /dev/scg	*/
+static	char	_scg_utrans_version[] = "uscsi-1.83";	/* The version for USCSI	*/
 
 #ifdef	USE_USCSI
-LOCAL	int	scgo_uhelp	__PR((SCSI *scgp, FILE *f));
-LOCAL	int	scgo_uopen	__PR((SCSI *scgp, char *device));
-LOCAL	int	scgo_volopen	__PR((SCSI *scgp, char *devname));
-LOCAL	int	scgo_openmedia	__PR((SCSI *scgp, char *mname));
-LOCAL	int	scgo_uclose	__PR((SCSI *scgp));
-LOCAL	int	scgo_ucinfo	__PR((int f, struct dk_cinfo *cp, int debug));
-LOCAL	int	scgo_ugettlun	__PR((int f, int *tgtp, int *lunp));
-LOCAL	long	scgo_umaxdma	__PR((SCSI *scgp, long amt));
-LOCAL	int	scgo_openide	__PR((void));
-LOCAL	BOOL	scgo_uhavebus	__PR((SCSI *scgp, int));
-LOCAL	int	scgo_ufileno	__PR((SCSI *scgp, int, int, int));
-LOCAL	int	scgo_uinitiator_id __PR((SCSI *scgp));
-LOCAL	int	scgo_uisatapi	__PR((SCSI *scgp));
-LOCAL	int	scgo_ureset	__PR((SCSI *scgp, int what));
-LOCAL	int	scgo_usend	__PR((SCSI *scgp));
+static	int	scgo_uhelp(SCSI *scgp, FILE *f);
+static	int	scgo_uopen(SCSI *scgp, char *device);
+static	int	scgo_volopen(SCSI *scgp, char *devname);
+static	int	scgo_openmedia(SCSI *scgp, char *mname);
+static	int	scgo_uclose(SCSI *scgp);
+static	int	scgo_ucinfo(int f, struct dk_cinfo *cp, int debug);
+static	int	scgo_ugettlun(int f, int *tgtp, int *lunp);
+static	long	scgo_umaxdma(SCSI *scgp, long amt);
+static	int	scgo_openide(void);
+static	BOOL	scgo_uhavebus(SCSI *scgp, int);
+static	int	scgo_ufileno(SCSI *scgp, int, int, int);
+static	int	scgo_uinitiator_id(SCSI *scgp);
+static	int	scgo_uisatapi(SCSI *scgp);
+static	int	scgo_ureset(SCSI *scgp, int what);
+static	int	scgo_usend(SCSI *scgp);
 
-LOCAL	int	have_volmgt = -1;
+static	int	have_volmgt = -1;
 
-LOCAL scg_ops_t sun_uscsi_ops = {
+static scg_ops_t sun_uscsi_ops = {
 	scgo_usend,
 	scgo_version,		/* Shared with SCG driver */
 	scgo_uhelp,
@@ -156,10 +156,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -183,10 +181,8 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "scg", "Generic transport independent SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
@@ -196,10 +192,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -277,9 +271,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	i;
 
@@ -294,10 +287,8 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	long	maxdma = MAX_DMA_OTHER;
 #if	!defined(__i386_) && !defined(i386)
@@ -337,10 +328,8 @@
 	return (maxdma);
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	if (scgp->local == NULL)
 		return (FALSE);
@@ -348,12 +337,8 @@
 	return (busno < 0 || busno >= MAX_SCG) ? FALSE : (scgfiles(scgp)[busno] >= 0);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (scgp->local == NULL)
 		return (-1);
@@ -361,9 +346,8 @@
 	return ((busno < 0 || busno >= MAX_SCG) ? -1 : scgfiles(scgp)[busno]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	int		id = -1;
 #ifdef	DKIO_GETCINFO
@@ -381,17 +365,14 @@
 	return (id);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	if (what == SCG_RESET_NOP)
 		return (0);
@@ -402,27 +383,23 @@
 	return (ioctl(scgp->fd, SCGIORESET, 0));
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	scgp->bufbase = (void *)valloc((size_t)amt);
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI	*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	scgp->scmd->target = scg_target(scgp);
 	return (ioctl(scgp->fd, SCGIO_CMD, scgp->scmd));
@@ -461,20 +438,16 @@
 #define	STATUS_ACA_ACTIVE		0x30
 #endif
 
-LOCAL int
-scgo_uhelp(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_uhelp(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "USCSI", "SCSI transport for targets known by Solaris drivers",
 		"USCSI:", "bus,target,lun", "USCSI:1,2,0", TRUE, TRUE);
 	return (0);
 }
 
-LOCAL int
-scgo_uopen(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_uopen(SCSI *scgp, char *device)
 {
 		int	busno	= scg_scsibus(scgp);
 		int	tgt	= scg_target(scgp);
@@ -643,10 +616,8 @@
 	return (nopen);
 }
 
-LOCAL int
-scgo_volopen(scgp, devname)
-	SCSI	*scgp;
-	char	*devname;
+static int
+scgo_volopen(SCSI *scgp, char *devname)
 {
 	int	oerr = geterrno();
 	int	f = -1;
@@ -734,10 +705,8 @@
 	return (f);
 }
 
-LOCAL int
-scgo_openmedia(scgp, mname)
-	SCSI	*scgp;
-	char	*mname;
+static int
+scgo_openmedia(SCSI *scgp, char *mname)
 {
 	int	f = -1;
 	char	*device = NULL;
@@ -786,9 +755,8 @@
 	return (f);
 }
 
-LOCAL int
-scgo_uclose(scgp)
-	SCSI	*scgp;
+static int
+scgo_uclose(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -811,11 +779,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_ucinfo(f, cp, debug)
-	int		f;
-	struct dk_cinfo *cp;
-	int		debug;
+static int
+scgo_ucinfo(int f, struct dk_cinfo *cp, int debug)
 {
 	fillbytes(cp, sizeof (*cp), '\0');
 
@@ -847,11 +812,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_ugettlun(f, tgtp, lunp)
-	int	f;
-	int	*tgtp;
-	int	*lunp;
+static int
+scgo_ugettlun(int f, int *tgtp, int *lunp)
 {
 	struct dk_cinfo ci;
 
@@ -864,10 +826,8 @@
 	return (0);
 }
 
-LOCAL long
-scgo_umaxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_umaxdma(SCSI *scgp, long amt)
 {
 	register int	b;
 	register int	t;
@@ -947,7 +907,7 @@
 }
 
 #if	defined(__i386_) || defined(i386)
-LOCAL int
+static int
 scgo_openide()
 {
 	char	buf[20];
@@ -968,10 +928,8 @@
 }
 #endif
 
-LOCAL BOOL
-scgo_uhavebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_uhavebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -987,12 +945,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_ufileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_ufileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (scgp->local == NULL ||
 	    busno < 0 || busno >= MAX_SCG ||
@@ -1003,16 +957,14 @@
 	return ((int)scglocal(scgp)->u.scg_files[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_uinitiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_uinitiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_uisatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_uisatapi(SCSI *scgp)
 {
 	char		devname[32];
 	char		symlinkname[MAXPATHLEN];
@@ -1036,10 +988,8 @@
 		return (FALSE);
 }
 
-LOCAL int
-scgo_ureset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_ureset(SCSI *scgp, int what)
 {
 	struct uscsi_cmd req;
 
@@ -1060,9 +1010,8 @@
 	return (ioctl(scgp->fd, USCSICMD, &req));
 }
 
-LOCAL int
-scgo_usend(scgp)
-	SCSI		*scgp;
+static int
+scgo_usend(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	struct uscsi_cmd req;

Modified: nonameyet/branches/cleanup/libscg/scsi-unixware.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-unixware.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-unixware.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -57,7 +57,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-unixware.c-1.36";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-unixware.c-1.36";	/* The version for this transport*/
 
 /* Max. number of scg scsibusses.  The real limit would be		*/
 /* MAX_HBA * MAX_BUS (which would be 32 * 8 on UnixWare 2.1/7.x),	*/
@@ -114,19 +114,19 @@
 #endif
 } scg2sdi_t;
 
-LOCAL	scg2sdi_t	sdidevs [MAX_SCG][MAX_TGT][MAX_LUN];
-LOCAL	BOOL		sdiinit = FALSE;
+static	scg2sdi_t	sdidevs [MAX_SCG][MAX_TGT][MAX_LUN];
+static	BOOL		sdiinit = FALSE;
 
 struct scg_local {
 	short	scgfiles[MAX_SCG][MAX_TGT][MAX_LUN];
 };
 #define	scglocal(p)	((struct scg_local *)((p)->local))
 
-LOCAL	int	unixware_init	__PR((SCSI *scgp));
-LOCAL	int	do_scg_cmd	__PR((SCSI *scgp, struct scg_cmd *sp));
-LOCAL	int	do_scg_sense	__PR((SCSI *scgp, struct scg_cmd *sp));
-LOCAL	FILE	*xpopen		__PR((char *cmd, char *type));
-LOCAL	int	xpclose		__PR((FILE *f));
+static	int	unixware_init(SCSI *scgp);
+static	int	do_scg_cmd(SCSI *scgp, struct scg_cmd *sp);
+static	int	do_scg_sense(SCSI *scgp, struct scg_cmd *sp);
+static	FILE	*xpopen(char *cmd, char *type);
+static	int	xpclose(FILE *f);
 
 /*
  * -------------------------------------------------------------------------
@@ -150,10 +150,8 @@
  * in applications.
  *
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -174,10 +172,8 @@
 }
 
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "SDI_SEND", "Generic SCSI",
 		"", "bus,target,lun", "1,2,0", TRUE, FALSE);
@@ -193,9 +189,8 @@
  *
  */
 
-LOCAL int
-unixware_init(scgp)
-	SCSI	*scgp;
+static int
+unixware_init(SCSI *scgp)
 {
 	FILE		*cmd;
 	int		hba = 0, bus = 0, scg = 0, tgt = 0, lun = 0;
@@ -471,10 +466,8 @@
 }
 
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -537,9 +530,8 @@
 }
 
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	register int	f;
 	register int	b;
@@ -571,19 +563,15 @@
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA);
 }
 
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -594,19 +582,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	register int	t;
 	register int	l;
@@ -625,12 +610,8 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= MAX_SCG ||
 	    tgt   < 0 || tgt   >= MAX_TGT ||
@@ -643,9 +624,8 @@
 	return ((int)scglocal(scgp)->scgfiles[busno][tgt][tlun]);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	register int	t;
 	register int	l;
@@ -670,19 +650,16 @@
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	/* if the new address method is used we know if this is ATAPI */
 
 	return ((sdidevs[scg_scsibus(scgp)][scg_target(scgp)][scg_lun(scgp)].flags & SDI_ATAPI) != 0);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	int	f = scgp->fd;
 
@@ -715,10 +692,8 @@
 	return (-1);
 }
 
-LOCAL int
-do_scg_cmd(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_cmd(SCSI *scgp, struct scg_cmd *sp)
 {
 	int			ret;
 	int			i;
@@ -837,10 +812,8 @@
 }
 
 
-LOCAL int
-do_scg_sense(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_sense(SCSI *scgp, struct scg_cmd *sp)
 {
 	int		ret;
 	struct scg_cmd	s_cmd;
@@ -866,9 +839,8 @@
 	return (ret);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int	ret;
@@ -901,12 +873,10 @@
  * This version of popen() is not usable more than once at a time.
  * Needed because /etc/scsi/pdiconfig will not work if euid != uid
  */
-LOCAL pid_t	po_pid;
+static pid_t	po_pid;
 
-LOCAL FILE *
-xpopen(cmd, type)
-	char	*cmd;
-	char	*type;
+static FILE *
+xpopen(char *cmd, char *type)
 {
 	FILE	*ret;
 	FILE	*pp[2];
@@ -938,9 +908,8 @@
 	return (pp[0]);
 }
 
-LOCAL int
-xpclose(f)
-	FILE	*f;
+static int
+xpclose(FILE *f)
 {
 	int	ret = 0;
 

Modified: nonameyet/branches/cleanup/libscg/scsi-vms.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-vms.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-vms.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -62,7 +62,7 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-vms.c-1.33";	/* The version for this transport*/
+static	char	_scg_trans_version[] = "scsi-vms.c-1.33";	/* The version for this transport*/
 
 #define	VMS_MAX_DK	4		/* DK[A-D] VMS device controllers */
 #define	VMS_MAX_GK	4		/* GK[A-D] VMS device controllers */
@@ -91,15 +91,15 @@
  * The offset of the busno value within its range is used to define the
  * third character, using the vmschar2[] array.
  */
-LOCAL	char	vmschar[]	= {'d', 'g', 'd'};
-LOCAL	char	vmschar1[]	= {'k', 'k', 'q'};
-LOCAL	char	vmschar2[]	= {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j',
+static	char	vmschar[]	= {'d', 'g', 'd'};
+static	char	vmschar1[]	= {'k', 'k', 'q'};
+static	char	vmschar2[]	= {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j',
 				    'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't',
 				    'u', 'v', 'w', 'x', 'y', 'z'};
 
 
-LOCAL	int	do_scg_cmd	__PR((SCSI *scgp, struct scg_cmd *sp));
-LOCAL	int	do_scg_sense	__PR((SCSI *scgp, struct scg_cmd *sp));
+static	int	do_scg_cmd(SCSI *scgp, struct scg_cmd *sp);
+static	int	do_scg_sense(SCSI *scgp, struct scg_cmd *sp);
 
 #define	DEVICE_NAMELEN 8
 
@@ -175,10 +175,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -198,20 +196,16 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "IO$_DIAGNOSE", "Generic SCSI",
 		"", "bus,target,lun", "1,2,0", FALSE, FALSE);
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -290,9 +284,8 @@
 	return (status);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	/*
 	 * XXX close gk_chan ???
@@ -306,46 +299,36 @@
 	return (status);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA_VMS);
 }
 
-LOCAL BOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	if (gk_chan == 0)
 		return (FALSE);
 	return (TRUE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (gk_chan == 0)
 		return (-1);
 	return (gk_chan);
 }
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	int	busno = scg_scsibus(scgp);
 
@@ -355,19 +338,15 @@
 	return (FALSE);
 }
 
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -377,19 +356,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL int
-do_scg_cmd(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_cmd(SCSI *scgp, struct scg_cmd *sp)
 {
 	char		*cmdadr;
 	int		notcmdretry;
@@ -523,10 +499,8 @@
 	return (0);
 }
 
-LOCAL int
-do_scg_sense(scgp, sp)
-	SCSI		*scgp;
-	struct scg_cmd	*sp;
+static int
+do_scg_sense(SCSI *scgp, struct scg_cmd *sp)
 {
 	int		ret;
 	struct scg_cmd	s_cmd;
@@ -551,9 +525,8 @@
 	return (ret);
 }
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd	*sp = scgp->scmd;
 	int	ret;

Modified: nonameyet/branches/cleanup/libscg/scsi-wnt.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsi-wnt.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsi-wnt.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -76,8 +76,8 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_version[] = "scsi-wnt.c-1.45";	/* The version for this transport*/
-LOCAL	char	_scg_itrans_version[] = "SPTI-scsi-wnt.c-1.45";	/* The version for SPTI */
+static	char	_scg_trans_version[] = "scsi-wnt.c-1.45";	/* The version for this transport*/
+static	char	_scg_itrans_version[] = "SPTI-scsi-wnt.c-1.45";	/* The version for SPTI */
 
 /*
  * Local defines and constants
@@ -99,35 +99,35 @@
 /*
  * Local variables
  */
-LOCAL	int	busses;
-LOCAL	DWORD	(*pfnGetASPI32SupportInfo)(void)		= NULL;
-LOCAL	DWORD	(*pfnSendASPI32Command)(LPSRB)			= NULL;
-LOCAL	BOOL	(*pfnGetASPI32Buffer)(PASPI32BUFF)		= NULL;
-LOCAL	BOOL	(*pfnFreeASPI32Buffer)(PASPI32BUFF)		= NULL;
-LOCAL	BOOL	(*pfnTranslateASPI32Address)(PDWORD, PDWORD)	= NULL;
+static	int	busses;
+static	DWORD	(*pfnGetASPI32SupportInfo)(void)		= NULL;
+static	DWORD	(*pfnSendASPI32Command)(LPSRB)			= NULL;
+static	BOOL	(*pfnGetASPI32Buffer)(PASPI32BUFF)		= NULL;
+static	BOOL	(*pfnFreeASPI32Buffer)(PASPI32BUFF)		= NULL;
+static	BOOL	(*pfnTranslateASPI32Address)(PDWORD, PDWORD)	= NULL;
 
-LOCAL	int	AspiLoaded			= 0;    /* ASPI or SPTI */
-LOCAL	HANDLE	hAspiLib			= NULL;	/* Used for Loadlib */
+static	int	AspiLoaded			= 0;    /* ASPI or SPTI */
+static	HANDLE	hAspiLib			= NULL;	/* Used for Loadlib */
 
 #define	MAX_DMA_WNT	(63L*1024L) /* ASPI-Driver  allows up to 64k ??? */
 
 /*
  * Local function prototypes
  */
-LOCAL	void	exit_func	__PR((void));
+static	void	exit_func(void);
 #ifdef DEBUG_WNTASPI
-LOCAL	void	DebugScsiSend	__PR((SCSI *scgp, SRB_ExecSCSICmd *s, int bDisplayBuffer));
+static	void	DebugScsiSend(SCSI *scgp, SRB_ExecSCSICmd *s, int bDisplayBuffer);
 #endif
-LOCAL	void	copy_sensedata	__PR((SRB_ExecSCSICmd *cp, struct scg_cmd *sp));
-LOCAL	void	set_error	__PR((SRB_ExecSCSICmd *cp, struct scg_cmd *sp));
-LOCAL	BOOL	open_driver	__PR((SCSI *scgp));
-LOCAL	BOOL	load_aspi	__PR((SCSI *scgp));
-LOCAL	BOOL	close_driver	__PR((void));
-LOCAL	int	ha_inquiry	__PR((SCSI *scgp, int id, SRB_HAInquiry	*ip));
+static	void	copy_sensedata(SRB_ExecSCSICmd *cp, struct scg_cmd *sp);
+static	void	set_error(SRB_ExecSCSICmd *cp, struct scg_cmd *sp);
+static	BOOL	open_driver(SCSI *scgp);
+static	BOOL	load_aspi(SCSI *scgp);
+static	BOOL	close_driver(void);
+static	int	ha_inquiry(SCSI *scgp, int id, SRB_HAInquiry	*ip);
 #ifdef	__USED__
-LOCAL	int	resetSCSIBus	__PR((SCSI *scgp));
+static	int	resetSCSIBus(SCSI *scgp);
 #endif
-LOCAL	int	scsiabort	__PR((SCSI *scgp, SRB_ExecSCSICmd *sp));
+static	int	scsiabort(SCSI *scgp, SRB_ExecSCSICmd *sp);
 
 
 /* SPTI Start ---------------------------------------------------------------*/
@@ -175,21 +175,21 @@
 	DRIVE	drive[NUM_MAX_NTSCSI_DRIVES];
 } SPTIGLOBAL;
 
-LOCAL	int	InitSCSIPT(void);
-LOCAL	int	DeinitSCSIPT(void);
-LOCAL	void	GetDriveInformation(BYTE i, DRIVE *pDrive);
-LOCAL	BYTE	SPTIGetNumAdapters(void);
-LOCAL	BYTE	SPTIGetDeviceIndex(BYTE ha, BYTE tgt, BYTE lun);
-LOCAL	DWORD	SPTIHandleHaInquiry(LPSRB_HAInquiry lpsrb);
-LOCAL	DWORD	SPTIExecSCSICommand(LPSRB_ExecSCSICmd lpsrb, int sptTimeOutValue, BOOL bBeenHereBefore);
-LOCAL	HANDLE	GetFileHandle(BYTE i, BOOL openshared);
+static	int	InitSCSIPT(void);
+static	int	DeinitSCSIPT(void);
+static	void	GetDriveInformation(BYTE i, DRIVE *pDrive);
+static	BYTE	SPTIGetNumAdapters(void);
+static	BYTE	SPTIGetDeviceIndex(BYTE ha, BYTE tgt, BYTE lun);
+static	DWORD	SPTIHandleHaInquiry(LPSRB_HAInquiry lpsrb);
+static	DWORD	SPTIExecSCSICommand(LPSRB_ExecSCSICmd lpsrb, int sptTimeOutValue, BOOL bBeenHereBefore);
+static	HANDLE	GetFileHandle(BYTE i, BOOL openshared);
 
-LOCAL	BOOL	bSCSIPTInit = FALSE;
-LOCAL	SPTIGLOBAL sptiglobal;
-LOCAL	BOOL	bUsingSCSIPT = FALSE;
-LOCAL	BOOL	bForceAccess = FALSE;
-LOCAL	int	sptihamax;
-LOCAL	USHORT	sptihasortarr[NUM_MAX_NTSCSI_HA];
+static	BOOL	bSCSIPTInit = FALSE;
+static	SPTIGLOBAL sptiglobal;
+static	BOOL	bUsingSCSIPT = FALSE;
+static	BOOL	bForceAccess = FALSE;
+static	int	sptihamax;
+static	USHORT	sptihasortarr[NUM_MAX_NTSCSI_HA];
 
 /*
  * Initialization of SCSI Pass Through Interface code.  Responsible for
@@ -199,7 +199,7 @@
  * send CDB with the INQUIRY command to it -- NT will automagically fill in
  * the PathId, TargetId, and Lun for us.
  */
-LOCAL int
+static int
 InitSCSIPT(void)
 {
 	BYTE	i;
@@ -306,7 +306,7 @@
 }
 
 
-LOCAL int
+static int
 DeinitSCSIPT(void)
 {
 	BYTE	i;
@@ -331,7 +331,7 @@
 /*
  * Returns the number of "adapters" present.
  */
-LOCAL BYTE
+static BYTE
 SPTIGetNumAdapters(void)
 {
 	BYTE	buf[256];
@@ -361,7 +361,7 @@
 }
 
 #include <ctype.h>
-LOCAL BOOL
+static BOOL
 w2k_or_newer(void)
 {
 	OSVERSIONINFO osver;
@@ -379,7 +379,7 @@
 	return (FALSE);
 }
 
-LOCAL BOOL
+static BOOL
 w2kstyle_create(void)
 {
 	OSVERSIONINFO osver;
@@ -425,7 +425,7 @@
  * GENERIC_WRITE access is beyond me...), the easist workaround is to just
  * try them both.
  */
-LOCAL HANDLE
+static HANDLE
 GetFileHandle(BYTE i, BOOL openshared)
 {
 	char	buf[12];
@@ -489,7 +489,7 @@
  * fills in a pDrive structure with information from a SCSI_INQUIRY
  * and obtains the ha:tgt:lun values via IOCTL_SCSI_GET_ADDRESS
  */
-LOCAL void
+static void
 GetDriveInformation(BYTE i, DRIVE *pDrive)
 {
 	HANDLE		fh;
@@ -605,7 +605,7 @@
 
 
 
-LOCAL DWORD
+static DWORD
 SPTIHandleHaInquiry(LPSRB_HAInquiry lpsrb)
 {
 	DWORD	*pMTL;
@@ -631,7 +631,7 @@
 /*
  * Looks up the index in the drive array for a given ha:tgt:lun triple
  */
-LOCAL BYTE
+static BYTE
 SPTIGetDeviceIndex(BYTE ha, BYTE tgt, BYTE lun)
 {
 	BYTE	i;
@@ -657,7 +657,7 @@
  * Converts ASPI-style SRB to SCSI Pass Through IOCTL
  */
 
-LOCAL DWORD
+static DWORD
 SPTIExecSCSICommand(LPSRB_ExecSCSICmd lpsrb, int sptTimeOutValue, BOOL bBeenHereBefore)
 {
 	BOOL	status;
@@ -763,7 +763,7 @@
 /* SPTI End -----------------------------------------------------------------*/
 
 
-LOCAL void
+static void
 exit_func()
 {
 	if (!close_driver())
@@ -775,10 +775,8 @@
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_version(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -800,10 +798,8 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_help(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_help(SCSI *scgp, FILE *f)
 {
 	__scg_help(f, "ASPI", "Generic transport independent SCSI",
 		"ASPI:", "bus,target,lun", "ASPI:1,2,0", TRUE, FALSE);
@@ -812,10 +808,8 @@
 	return (0);
 }
 
-LOCAL int
-scgo_open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_open(SCSI *scgp, char *device)
 {
 	int	busno	= scg_scsibus(scgp);
 	int	tgt	= scg_target(scgp);
@@ -920,26 +914,21 @@
 	return (1);
 }
 
-LOCAL int
-scgo_close(scgp)
-	SCSI	*scgp;
+static int
+scgo_close(SCSI *scgp)
 {
 	exit_func();
 	return (0);
 }
 
-LOCAL long
-scgo_maxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_maxdma(SCSI *scgp, long amt)
 {
 	return (MAX_DMA_WNT);
 }
 
-LOCAL void *
-scgo_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_getbuf(SCSI *scgp, long amt)
 {
 	if (scgp->debug > 0) {
 		js_fprintf((FILE *)scgp->errfile,
@@ -949,19 +938,16 @@
 	return (scgp->bufbase);
 }
 
-LOCAL void
-scgo_freebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_freebuf(SCSI *scgp)
 {
 	if (scgp->bufbase)
 		free(scgp->bufbase);
 	scgp->bufbase = NULL;
 }
 
-LOCAL __SBOOL
-scgo_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static __SBOOL
+scgo_havebus(SCSI *scgp, int busno)
 {
 	if (busno < 0 || busno >= busses)
 		return (FALSE);
@@ -969,12 +955,8 @@
 	return (TRUE);
 }
 
-LOCAL int
-scgo_fileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	if (busno < 0 || busno >= busses ||
 	    tgt < 0 || tgt >= MAX_TGT ||
@@ -988,9 +970,8 @@
 }
 
 
-LOCAL int
-scgo_initiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_initiator_id(SCSI *scgp)
 {
 	SRB_HAInquiry	s;
 
@@ -999,9 +980,8 @@
 	return (s.HA_SCSI_ID);
 }
 
-LOCAL int
-scgo_isatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_isatapi(SCSI *scgp)
 {
 	return (-1);	/* XXX Need to add real test */
 }
@@ -1010,10 +990,8 @@
 /*
  * XXX scgo_reset not yet tested
  */
-LOCAL int
-scgo_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_reset(SCSI *scgp, int what)
 {
 
 	DWORD			Status = 0;
@@ -1126,11 +1104,8 @@
 
 
 #ifdef DEBUG_WNTASPI
-LOCAL void
-DebugScsiSend(scgp, s, bDisplayBuffer)
-	SCSI		*scgp;
-	SRB_ExecSCSICmd	*s;
-	int		bDisplayBuffer;
+static void
+DebugScsiSend(SCSI *scgp, SRB_ExecSCSICmd *s, int bDisplayBuffer)
 {
 	int i;
 
@@ -1165,10 +1140,8 @@
 }
 #endif
 
-LOCAL void
-copy_sensedata(cp, sp)
-	SRB_ExecSCSICmd	*cp;
-	struct scg_cmd	*sp;
+static void
+copy_sensedata(SRB_ExecSCSICmd *cp, struct scg_cmd *sp)
 {
 	sp->sense_count	= cp->SRB_SenseLen;
 	if (sp->sense_count > sp->sense_len)
@@ -1183,10 +1156,8 @@
 /*
  * Set error flags
  */
-LOCAL void
-set_error(cp, sp)
-	SRB_ExecSCSICmd	*cp;
-	struct scg_cmd	*sp;
+static void
+set_error(SRB_ExecSCSICmd *cp, struct scg_cmd *sp)
 {
 	switch (cp->SRB_Status) {
 
@@ -1270,9 +1241,8 @@
 	char			pad[32];
 };
 
-LOCAL int
-scgo_send(scgp)
-	SCSI		*scgp;
+static int
+scgo_send(SCSI *scgp)
 {
 	struct scg_cmd		*sp = scgp->scmd;
 	DWORD			Status = 0;
@@ -1438,9 +1408,8 @@
  *  Preconditions: ASPI Router driver has be loaded			   *
  *									   *
  ***************************************************************************/
-LOCAL BOOL
-open_driver(scgp)
-	SCSI	*scgp;
+static BOOL
+open_driver(SCSI *scgp)
 {
 	DWORD	astatus;
 	BYTE	HACount;
@@ -1540,9 +1509,8 @@
 	return (TRUE);
 }
 
-LOCAL BOOL
-load_aspi(scgp)
-	SCSI	*scgp;
+static BOOL
+load_aspi(SCSI *scgp)
 {
 #ifdef	__CYGWIN32__
 	hAspiLib = dlopen("WNASPI32", RTLD_NOW);
@@ -1606,7 +1574,7 @@
  *  Preconditions: ASPI Router driver has be opened with open_driver	   *
  *									   *
  ***************************************************************************/
-LOCAL BOOL
+static BOOL
 close_driver()
 {
 	if (--AspiLoaded > 0)
@@ -1642,11 +1610,8 @@
 	return (TRUE);
 }
 
-LOCAL int
-ha_inquiry(scgp, id, ip)
-	SCSI		*scgp;
-	int		id;
-	SRB_HAInquiry	*ip;
+static int
+ha_inquiry(SCSI *scgp, int id, SRB_HAInquiry *ip)
 {
 	DWORD		Status;
 
@@ -1674,9 +1639,8 @@
 }
 
 #ifdef	__USED__
-LOCAL int
-resetSCSIBus(scgp)
-	SCSI	*scgp;
+static int
+resetSCSIBus(SCSI *scgp)
 {
 	DWORD			Status;
 	HANDLE			Event;
@@ -1744,10 +1708,8 @@
 }
 #endif	/* __USED__ */
 
-LOCAL int
-scsiabort(scgp, sp)
-	SCSI		*scgp;
-	SRB_ExecSCSICmd	*sp;
+static int
+scsiabort(SCSI *scgp, SRB_ExecSCSICmd *sp)
 {
 	DWORD			Status = 0;
 	SRB_Abort		s;

Modified: nonameyet/branches/cleanup/libscg/scsierrs.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsierrs.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsierrs.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -56,12 +56,9 @@
 
 #define	SMO_C501
 
-EXPORT	const char	*scg_sensemsg	__PR((int, int, int,
-						const char **, char *, int maxcnt));
-EXPORT	int		scg__errmsg	__PR((SCSI *scgp, char *obuf, int maxcnt,
-						struct scsi_sense *,
-						struct scsi_status *,
-						int));
+const char	*scg_sensemsg(int, int, int, const char **, char *, int maxcnt);
+int scg__errmsg(SCSI *scgp, char *obuf, int maxcnt, struct scsi_sense *, 
+					 struct scsi_status *, int);
 /*
  * Map old non extended sense to sense key.
  */
@@ -695,15 +692,9 @@
 	NULL
 };
 
-EXPORT
 const char *
-scg_sensemsg(ctype, code, qual, vec, sbuf, maxcnt)
-	register 	int	ctype;
-	register 	int	code;
-	register 	int	qual;
-	register const char	**vec;
-			char	*sbuf;
-			int	maxcnt;
+scg_sensemsg(register int ctype, register int code, register int qual, 
+				 register const char **vec, char *sbuf, int maxcnt)
 {
 	register int i;
 
@@ -776,14 +767,10 @@
 }
 
 #undef	sense	/*XXX JS Hack, solange scgio.h noch nicht fertig ist */
-EXPORT int
-scg__errmsg(scgp, obuf, maxcnt, sense, status, sense_code)
-	SCSI	*scgp;
-	char	*obuf;
-	int	maxcnt;
-	register struct scsi_sense	*sense;
-	register struct scsi_status	*status;
-	int				sense_code;
+int
+scg__errmsg(SCSI *scgp, char *obuf, int maxcnt, 
+				register struct scsi_sense *sense, 
+				register struct scsi_status *status, int sense_code)
 {
 	char	sbuf[80];
 	const char *sensemsg, *cmdname, *sensekey;
@@ -996,7 +983,7 @@
 }
 
 
-main()
+int main(int argc, char *argv[])
 {
 	int	i;
 

Modified: nonameyet/branches/cleanup/libscg/scsihack.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsihack.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsihack.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -77,24 +77,24 @@
 extern	int	errno;
 #endif
 
-LOCAL	int	scgo_send	__PR((SCSI *scgp));
-LOCAL	char *	scgo_version	__PR((SCSI *scgp, int what));
-LOCAL	int	scgo_help	__PR((SCSI *scgp, FILE *f));
-LOCAL	int	scgo_open	__PR((SCSI *scgp, char *device));
-LOCAL	int	scgo_close	__PR((SCSI *scgp));
-LOCAL	long	scgo_maxdma	__PR((SCSI *scgp, long amt));
-LOCAL	void *	scgo_getbuf	__PR((SCSI *scgp, long amt));
-LOCAL	void	scgo_freebuf	__PR((SCSI *scgp));
+static	int	scgo_send(SCSI *scgp);
+static	char *scgo_version(SCSI *scgp, int what);
+static	int	scgo_help(SCSI *scgp, FILE *f);
+static	int	scgo_open(SCSI *scgp, char *device);
+static	int	scgo_close(SCSI *scgp);
+static	long	scgo_maxdma(SCSI *scgp, long amt);
+static	void *scgo_getbuf(SCSI *scgp, long amt);
+static	void	scgo_freebuf(SCSI *scgp);
 
-LOCAL	BOOL	scgo_havebus	__PR((SCSI *scgp, int busno));
-LOCAL	int	scgo_fileno	__PR((SCSI *scgp, int busno, int tgt, int tlun));
-LOCAL	int	scgo_initiator_id __PR((SCSI *scgp));
-LOCAL	int	scgo_isatapi	__PR((SCSI *scgp));
-LOCAL	int	scgo_reset	__PR((SCSI *scgp, int what));
+static	BOOL	scgo_havebus(SCSI *scgp, int busno);
+static	int	scgo_fileno(SCSI *scgp, int busno, int tgt, int tlun);
+static	int	scgo_initiator_id(SCSI *scgp);
+static	int	scgo_isatapi(SCSI *scgp);
+static	int	scgo_reset(SCSI *scgp, int what);
 
-LOCAL	char	_scg_auth_cdrkit[]	= "cdrkit-team";	/* The author for this module	*/
+static	char	_scg_auth_cdrkit[]	= "cdrkit-team";	/* The author for this module	*/
 
-EXPORT scg_ops_t scg_std_ops = {
+scg_ops_t scg_std_ops = {
 	scgo_send,
 	scgo_version,
 	scgo_help,
@@ -291,23 +291,23 @@
 #define	scgo_dsend		scgo_send
 #endif	/* SCSI_IMPL */
 
-LOCAL	int	scgo_dsend	__PR((SCSI *scgp));
-LOCAL	char *	scgo_dversion	__PR((SCSI *scgp, int what));
-LOCAL	int	scgo_dhelp	__PR((SCSI *scgp, FILE *f));
-LOCAL	int	scgo_nohelp	__PR((SCSI *scgp, FILE *f));
-LOCAL	int	scgo_ropen	__PR((SCSI *scgp, char *device));
-LOCAL	int	scgo_dopen	__PR((SCSI *scgp, char *device));
-LOCAL	int	scgo_dclose	__PR((SCSI *scgp));
-LOCAL	long	scgo_dmaxdma	__PR((SCSI *scgp, long amt));
-LOCAL	void *	scgo_dgetbuf	__PR((SCSI *scgp, long amt));
-LOCAL	void	scgo_dfreebuf	__PR((SCSI *scgp));
-LOCAL	BOOL	scgo_dhavebus	__PR((SCSI *scgp, int busno));
-LOCAL	int	scgo_dfileno	__PR((SCSI *scgp, int busno, int tgt, int tlun));
-LOCAL	int	scgo_dinitiator_id __PR((SCSI *scgp));
-LOCAL	int	scgo_disatapi	__PR((SCSI *scgp));
-LOCAL	int	scgo_dreset	__PR((SCSI *scgp, int what));
+static	int	scgo_dsend(SCSI *scgp);
+static	char *scgo_dversion(SCSI *scgp, int what);
+static	int	scgo_dhelp(SCSI *scgp, FILE *f);
+static	int	scgo_nohelp(SCSI *scgp, FILE *f);
+static	int	scgo_ropen(SCSI *scgp, char *device);
+static	int	scgo_dopen(SCSI *scgp, char *device);
+static	int	scgo_dclose(SCSI *scgp);
+static	long	scgo_dmaxdma(SCSI *scgp, long amt);
+static	void *scgo_dgetbuf(SCSI *scgp, long amt);
+static	void	scgo_dfreebuf(SCSI *scgp);
+static	BOOL	scgo_dhavebus(SCSI *scgp, int busno);
+static	int	scgo_dfileno(SCSI *scgp, int busno, int tgt, int tlun);
+static	int	scgo_dinitiator_id(SCSI *scgp);
+static	int	scgo_disatapi(SCSI *scgp);
+static	int	scgo_dreset(SCSI *scgp, int what);
 
-EXPORT scg_ops_t scg_remote_ops = {
+scg_ops_t scg_remote_ops = {
 	scgo_dsend,
 	scgo_dversion,
 	scgo_nohelp,
@@ -323,7 +323,7 @@
 	scgo_dreset,
 };
 
-EXPORT scg_ops_t scg_dummy_ops = {
+scg_ops_t scg_dummy_ops = {
 	scgo_dsend,
 	scgo_dversion,
 	scgo_dhelp,
@@ -346,17 +346,15 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_trans_dversion[] = "scsihack.c-1.44";	/* The version for this transport*/
+static	char	_scg_trans_dversion[] = "scsihack.c-1.44";	/* The version for this transport*/
 
 /*
  * Return version information for the low level SCSI transport code.
  * This has been introduced to make it easier to trace down problems
  * in applications.
  */
-LOCAL char *
-scgo_dversion(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static char *
+scgo_dversion(SCSI *scgp, int what)
 {
 	if (scgp != (SCSI *)0) {
 		switch (what) {
@@ -376,128 +374,101 @@
 	return ((char *)0);
 }
 
-LOCAL int
-scgo_dhelp(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_dhelp(SCSI *scgp, FILE *f)
 {
 	printf("None.\n");
 	return (0);
 }
 
-LOCAL int
-scgo_nohelp(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static int
+scgo_nohelp(SCSI *scgp, FILE *f)
 {
 	return (0);
 }
 
-LOCAL int
-scgo_ropen(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_ropen(SCSI *scgp, char *device)
 {
 	comerrno(EX_BAD, "No remote SCSI transport available.\n");
 	return (-1);	/* Keep lint happy */
 }
 
 #ifndef	SCSI_IMPL
-LOCAL int
-scgo_dopen(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_dopen(SCSI *scgp, char *device)
 {
 	comerrno(EX_BAD, "No local SCSI transport implementation for this architecture.\n");
 	return (-1);	/* Keep lint happy */
 }
 #else
-LOCAL int
-scgo_dopen(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+static int
+scgo_dopen(SCSI *scgp, char *device)
 {
 	comerrno(EX_BAD, "SCSI open usage error.\n");
 	return (-1);	/* Keep lint happy */
 }
 #endif	/* SCSI_IMPL */
 
-LOCAL int
-scgo_dclose(scgp)
-	SCSI	*scgp;
+static int
+scgo_dclose(SCSI *scgp)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL long
-scgo_dmaxdma(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static long
+scgo_dmaxdma(SCSI *scgp, long amt)
 {
 	errno = EINVAL;
 	return	(0L);
 }
 
-LOCAL void *
-scgo_dgetbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+static void *
+scgo_dgetbuf(SCSI *scgp, long amt)
 {
 	errno = EINVAL;
 	return ((void *)0);
 }
 
-LOCAL void
-scgo_dfreebuf(scgp)
-	SCSI	*scgp;
+static void
+scgo_dfreebuf(SCSI *scgp)
 {
 }
 
-LOCAL BOOL
-scgo_dhavebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+static BOOL
+scgo_dhavebus(SCSI *scgp, int busno)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_dfileno(scgp, busno, tgt, tlun)
-	SCSI	*scgp;
-	int	busno;
-	int	tgt;
-	int	tlun;
+static int
+scgo_dfileno(SCSI *scgp, int busno, int tgt, int tlun)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_dinitiator_id(scgp)
-	SCSI	*scgp;
+static int
+scgo_dinitiator_id(SCSI *scgp)
 {
 	return (-1);
 }
 
-LOCAL int
-scgo_disatapi(scgp)
-	SCSI	*scgp;
+static int
+scgo_disatapi(SCSI *scgp)
 {
 	return (FALSE);
 }
 
-LOCAL int
-scgo_dreset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+static int
+scgo_dreset(SCSI *scgp, int what)
 {
 	errno = EINVAL;
 	return (-1);
 }
 
-LOCAL int
-scgo_dsend(scgp)
-	SCSI	*scgp;
+static int
+scgo_dsend(SCSI *scgp)
 {
 	errno = EINVAL;
 	return (-1);

Modified: nonameyet/branches/cleanup/libscg/scsihelp.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsihelp.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsihelp.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -43,23 +43,12 @@
 
 #include <scg/scsitransp.h>
 
-EXPORT	void	__scg_help	__PR((FILE *f, char *name, char *tcomment,
-					char *tind,
-					char *tspec,
-					char *texample,
-					BOOL mayscan,
-					BOOL bydev));
+void	__scg_help(FILE *f, char *name, char *tcomment, char *tind, char *tspec,
+					  char *texample, BOOL mayscan, BOOL bydev);
 
-EXPORT void
-__scg_help(f, name, tcomment, tind, tspec, texample, mayscan, bydev)
-	FILE	*f;
-	char	*name;
-	char	*tcomment;
-	char	*tind;
-	char	*tspec;
-	char	*texample;
-	BOOL	mayscan;
-	BOOL	bydev;
+void
+__scg_help(FILE *f, char *name, char *tcomment, char *tind, char *tspec, 
+			  char *texample, BOOL mayscan, BOOL bydev)
 {
 	fprintf(f, "\nTransport name:		%s\n", name);
 	fprintf(f, "Transport descr.:	%s\n", tcomment);

Modified: nonameyet/branches/cleanup/libscg/scsiopen.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsiopen.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsiopen.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -71,17 +71,16 @@
 
 extern	int	lverbose;
 
-EXPORT	SCSI	*scg_open	__PR((char *scsidev, char *errs, int slen, int debug,
-								int be_verbose));
-EXPORT	int	scg_help	__PR((FILE *f));
-LOCAL	int	scg_scandev	__PR((char *devp, char *errs, int slen,
-							int *busp, int *tgtp, int *lunp));
-EXPORT	int	scg_close	__PR((SCSI * scgp));
+SCSI	*scg_open(char *scsidev, char *errs, int slen, int debug, int be_verbose);
+int	scg_help(FILE *f);
+static	int	scg_scandev(char *devp, char *errs, int slen, int *busp, 
+									int *tgtp, int *lunp);
+int	scg_close(SCSI * scgp);
 
-EXPORT	void	scg_settimeout	__PR((SCSI * scgp, int timeout));
+void	scg_settimeout(SCSI * scgp, int timeout);
 
-EXPORT	SCSI	*scg_smalloc	__PR((void));
-EXPORT	void	scg_sfree	__PR((SCSI *scgp));
+SCSI	*scg_smalloc(void);
+void	scg_sfree(SCSI *scgp);
 
 /*
  * Open a SCSI device.
@@ -102,13 +101,8 @@
  *	 must always be known. If the OS cannot map it, it must be
  *	 specified on command line.
  */
-EXPORT SCSI *
-scg_open(scsidev, errs, slen, debug, be_verbose)
-	char	*scsidev;
-	char	*errs;
-	int	slen;
-	int	debug;
-	int	be_verbose;
+SCSI *
+scg_open(char *scsidev, char *errs, int slen, int debug, int be_verbose)
 {
 	char	devname[256];
 	char	*devp = NULL;
@@ -288,9 +282,8 @@
 	return (scgp);
 }
 
-EXPORT int
-scg_help(f)
-	FILE	*f;
+int
+scg_help(FILE *f)
 {
 	SCSI	*scgp;
 
@@ -313,14 +306,8 @@
  * Check for bad syntax and invalid values.
  * This is definitely better than using scanf() as it checks for syntax errors.
  */
-LOCAL int
-scg_scandev(devp, errs, slen, busp, tgtp, lunp)
-	char	*devp;
-	char	*errs;
-	int	slen;
-	int	*busp;
-	int	*tgtp;
-	int	*lunp;
+static int
+scg_scandev(char *devp, char *errs, int slen, int *busp, int *tgtp, int *lunp)
 {
 	int	x1, x2, x3;
 	int	n = 0;
@@ -384,19 +371,16 @@
 	return (n);
 }
 
-EXPORT int
-scg_close(scgp)
-	SCSI	*scgp;
+int
+scg_close(SCSI *scgp)
 {
 	scg__close(scgp);
 	scg_sfree(scgp);
 	return (0);
 }
 
-EXPORT void
-scg_settimeout(scgp, timeout)
-	SCSI	*scgp;
-	int	timeout;
+void
+scg_settimeout(SCSI *scgp, int timeout)
 {
 #ifdef	nonono
 	if (timeout >= 0)
@@ -406,7 +390,7 @@
 #endif
 }
 
-EXPORT SCSI *
+SCSI *
 scg_smalloc()
 {
 	SCSI	*scgp;
@@ -451,9 +435,8 @@
 	return ((SCSI *)0);
 }
 
-EXPORT void
-scg_sfree(scgp)
-	SCSI	*scgp;
+void
+scg_sfree(SCSI *scgp)
 {
 	if (scgp->cmdstart)
 		free(scgp->cmdstart);

Modified: nonameyet/branches/cleanup/libscg/scsitransp.c
===================================================================
--- nonameyet/branches/cleanup/libscg/scsitransp.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libscg/scsitransp.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -63,68 +63,68 @@
  *	Choose your name instead of "schily" and make clear that the version
  *	string is related to a modified source.
  */
-LOCAL	char	_scg_version[]		= "0.8ubuntu1+debburn1";	/* The global libscg version	*/
-LOCAL	char	_scg_auth_ubuntu[]	= "debburn project";	/* The author for this module	*/
+static	char	_scg_version[]		= "0.8ubuntu1+debburn1";	/* The global libscg version	*/
+static	char	_scg_auth_ubuntu[]	= "debburn project";	/* The author for this module	*/
 
 #define	DEFTIMEOUT	20	/* Default timeout for SCSI command transport */
 
-EXPORT	char	*scg_version	__PR((SCSI *scgp, int what));
-EXPORT	int	scg__open	__PR((SCSI *scgp, char *device));
-EXPORT	int	scg__close	__PR((SCSI *scgp));
-EXPORT	BOOL	scg_havebus	__PR((SCSI *scgp, int));
-EXPORT	int	scg_initiator_id __PR((SCSI *scgp));
-EXPORT	int	scg_isatapi	__PR((SCSI *scgp));
-EXPORT	int	scg_reset	__PR((SCSI *scgp, int what));
-EXPORT	void	*scg_getbuf	__PR((SCSI *scgp, long));
-EXPORT	void	scg_freebuf	__PR((SCSI *scgp));
-EXPORT	long	scg_bufsize	__PR((SCSI *scgp, long));
-EXPORT	void	scg_setnonstderrs __PR((SCSI *scgp, const char **));
-EXPORT	BOOL	scg_yes		__PR((char *));
+char	*scg_version(SCSI *scgp, int what);
+int	scg__open(SCSI *scgp, char *device);
+int	scg__close(SCSI *scgp);
+BOOL	scg_havebus(SCSI *scgp, int);
+int	scg_initiator_id(SCSI *scgp);
+int	scg_isatapi(SCSI *scgp);
+int	scg_reset(SCSI *scgp, int what);
+void	*scg_getbuf(SCSI *scgp, long);
+void	scg_freebuf(SCSI *scgp);
+long	scg_bufsize(SCSI *scgp, long);
+void	scg_setnonstderrs(SCSI *scgp, const char **);
+BOOL	scg_yes(char *);
 #ifdef	nonono
-LOCAL	void	scg_sighandler	__PR((int));
+static	void	scg_sighandler(int);
 #endif
-EXPORT	int	scg_cmd		__PR((SCSI *scgp));
-EXPORT	void	scg_vhead	__PR((SCSI *scgp));
-EXPORT	int	scg_svhead	__PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	int	scg_vtail	__PR((SCSI *scgp));
-EXPORT	int	scg_svtail	__PR((SCSI *scgp, int *retp, char *buf, int maxcnt));
-EXPORT	void	scg_vsetup	__PR((SCSI *scgp));
-EXPORT	int	scg_getresid	__PR((SCSI *scgp));
-EXPORT	int	scg_getdmacnt	__PR((SCSI *scgp));
-EXPORT	BOOL	scg_cmd_err	__PR((SCSI *scgp));
-EXPORT	void	scg_printerr	__PR((SCSI *scgp));
-EXPORT	void	scg_fprinterr	__PR((SCSI *scgp, FILE *f));
-EXPORT	int	scg_sprinterr	__PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	int	scg__sprinterr	__PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	void	scg_printcdb	__PR((SCSI *scgp));
-EXPORT	int	scg_sprintcdb	__PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	void	scg_printwdata	__PR((SCSI *scgp));
-EXPORT	int	scg_sprintwdata	__PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	void	scg_printrdata	__PR((SCSI *scgp));
-EXPORT	int	scg_sprintrdata	__PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	void	scg_printresult	__PR((SCSI *scgp));
-EXPORT	int	scg_sprintresult __PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	void	scg_printstatus	__PR((SCSI *scgp));
-EXPORT	int	scg_sprintstatus __PR((SCSI *scgp, char *buf, int maxcnt));
-EXPORT	void	scg_fprbytes	__PR((FILE *, char *, unsigned char *, int));
-EXPORT	void	scg_fprascii	__PR((FILE *, char *, unsigned char *, int));
-EXPORT	void	scg_prbytes	__PR((char *, unsigned char *, int));
-EXPORT	void	scg_prascii	__PR((char *, unsigned char *, int));
-EXPORT	int	scg_sprbytes	__PR((char *buf, int maxcnt, char *, unsigned char *, int));
-EXPORT	int	scg_sprascii	__PR((char *buf, int maxcnt, char *, unsigned char *, int));
-EXPORT	void	scg_fprsense	__PR((FILE *f, unsigned char *, int));
-EXPORT	int	scg_sprsense	__PR((char *buf, int maxcnt, unsigned char *, int));
-EXPORT	void	scg_prsense	__PR((unsigned char *, int));
-EXPORT	int	scg_cmd_status	__PR((SCSI *scgp));
-EXPORT	int	scg_sense_key	__PR((SCSI *scgp));
-EXPORT	int	scg_sense_code	__PR((SCSI *scgp));
-EXPORT	int	scg_sense_qual	__PR((SCSI *scgp));
-EXPORT	unsigned char *scg_sense_table	__PR((SCSI *scgp));
-EXPORT	void	scg_fprintdev	__PR((FILE *, struct scsi_inquiry *));
-EXPORT	void	scg_printdev	__PR((struct scsi_inquiry *));
-EXPORT	int	scg_printf	__PR((SCSI *scgp, const char *form, ...));
-EXPORT	int	scg_errflush	__PR((SCSI *scgp));
-EXPORT	int	scg_errfflush	__PR((SCSI *scgp, FILE *f));
+int	scg_cmd(SCSI *scgp);
+void	scg_vhead(SCSI *scgp);
+int	scg_svhead(SCSI *scgp, char *buf, int maxcnt);
+int	scg_vtail(SCSI *scgp);
+int	scg_svtail(SCSI *scgp, int *retp, char *buf, int maxcnt);
+void	scg_vsetup(SCSI *scgp);
+int	scg_getresid(SCSI *scgp);
+int	scg_getdmacnt(SCSI *scgp);
+BOOL	scg_cmd_err(SCSI *scgp);
+void	scg_printerr(SCSI *scgp);
+void	scg_fprinterr(SCSI *scgp, FILE *f);
+int	scg_sprinterr(SCSI *scgp, char *buf, int maxcnt);
+int	scg__sprinterr(SCSI *scgp, char *buf, int maxcnt);
+void	scg_printcdb(SCSI *scgp);
+int	scg_sprintcdb(SCSI *scgp, char *buf, int maxcnt);
+void	scg_printwdata(SCSI *scgp);
+int	scg_sprintwdata(SCSI *scgp, char *buf, int maxcnt);
+void	scg_printrdata(SCSI *scgp);
+int	scg_sprintrdata(SCSI *scgp, char *buf, int maxcnt);
+void	scg_printresult(SCSI *scgp);
+int	scg_sprintresult(SCSI *scgp, char *buf, int maxcnt);
+void	scg_printstatus(SCSI *scgp);
+int	scg_sprintstatus(SCSI *scgp, char *buf, int maxcnt);
+void	scg_fprbytes(FILE *, char *, unsigned char *, int);
+void	scg_fprascii(FILE *, char *, unsigned char *, int);
+void	scg_prbytes(char *, unsigned char *, int);
+void	scg_prascii(char *, unsigned char *, int);
+int	scg_sprbytes(char *buf, int maxcnt, char *, unsigned char *, int);
+int	scg_sprascii(char *buf, int maxcnt, char *, unsigned char *, int);
+void	scg_fprsense(FILE *f, unsigned char *, int);
+int	scg_sprsense(char *buf, int maxcnt, unsigned char *, int);
+void	scg_prsense(unsigned char *, int);
+int	scg_cmd_status(SCSI *scgp);
+int	scg_sense_key(SCSI *scgp);
+int	scg_sense_code(SCSI *scgp);
+int	scg_sense_qual(SCSI *scgp);
+unsigned char *scg_sense_table(SCSI *scgp);
+void	scg_fprintdev(FILE *, struct scsi_inquiry *);
+void	scg_printdev(struct scsi_inquiry *);
+int	scg_printf(SCSI *scgp, const char *form, ...);
+int	scg_errflush(SCSI *scgp);
+int	scg_errfflush(SCSI *scgp, FILE *f);
 
 /*
  * Return version information for the SCSI transport code.
@@ -134,10 +134,8 @@
  * If scgp is NULL, return general library version information.
  * If scgp is != NULL, return version information for the low level transport.
  */
-EXPORT char *
-scg_version(scgp, what)
-	SCSI	*scgp;
-	int	what;
+char *
+scg_version(SCSI *scgp, int what)
 {
 	if (scgp == (SCSI *)0) {
 		switch (what) {
@@ -162,10 +160,8 @@
 /*
  * Call low level SCSI open routine from transport abstraction layer.
  */
-EXPORT int
-scg__open(scgp, device)
-	SCSI	*scgp;
-	char	*device;
+int
+scg__open(SCSI *scgp, char *device)
 {
 	int	ret;
 	scg_ops_t *ops;
@@ -223,9 +219,8 @@
 /*
  * Call low level SCSI close routine from transport abstraction layer.
  */
-EXPORT int
-scg__close(scgp)
-	SCSI	*scgp;
+int
+scg__close(SCSI *scgp)
 {
 	return (SCGO_CLOSE(scgp));
 }
@@ -233,10 +228,8 @@
 /*
  * Retrieve max DMA count for this target.
  */
-EXPORT long
-scg_bufsize(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+long
+scg_bufsize(SCSI *scgp, long amt)
 {
 	long	maxdma;
 
@@ -253,10 +246,8 @@
 /*
  * Allocate a buffer that may be used for DMA.
  */
-EXPORT void *
-scg_getbuf(scgp, amt)
-	SCSI	*scgp;
-	long	amt;
+void *
+scg_getbuf(SCSI *scgp, long amt)
 {
 	void	*buf;
 
@@ -271,9 +262,8 @@
 /*
  * Free DMA buffer.
  */
-EXPORT void
-scg_freebuf(scgp)
-	SCSI	*scgp;
+void
+scg_freebuf(SCSI *scgp)
 {
 	SCGO_FREEBUF(scgp);
 	scgp->bufptr = NULL;
@@ -282,10 +272,8 @@
 /*
  * Check if 'busno' is a valid SCSI bus number.
  */
-EXPORT BOOL
-scg_havebus(scgp, busno)
-	SCSI	*scgp;
-	int	busno;
+BOOL
+scg_havebus(SCSI *scgp, int busno)
 {
 	return (SCGO_HAVEBUS(scgp, busno));
 }
@@ -293,9 +281,8 @@
 /*
  * Return SCSI initiator ID for current SCSI bus if available.
  */
-EXPORT int
-scg_initiator_id(scgp)
-	SCSI	*scgp;
+int
+scg_initiator_id(SCSI *scgp)
 {
 	return (SCGO_INITIATOR_ID(scgp));
 }
@@ -303,9 +290,8 @@
 /*
  * Return a hint whether current SCSI target refers to a ATAPI device.
  */
-EXPORT int
-scg_isatapi(scgp)
-	SCSI	*scgp;
+int
+scg_isatapi(SCSI *scgp)
 {
 	return (SCGO_ISATAPI(scgp));
 }
@@ -313,10 +299,8 @@
 /*
  * Reset SCSI bus or target.
  */
-EXPORT int
-scg_reset(scgp, what)
-	SCSI	*scgp;
-	int	what;
+int
+scg_reset(SCSI *scgp, int what)
 {
 	return (SCGO_RESET(scgp, what));
 }
@@ -326,10 +310,8 @@
  * To clear additional error table, call scg_setnonstderrs(scgp, NULL);
  * Note: do not use this when scanning the SCSI bus.
  */
-EXPORT void
-scg_setnonstderrs(scgp, vec)
-	SCSI	*scgp;
-	const char **vec;
+void
+scg_setnonstderrs(SCSI *scgp, const char **vec)
 {
 	scgp->nonstderrs = vec;
 }
@@ -337,9 +319,8 @@
 /*
  * Simple Yes/No answer checker.
  */
-EXPORT BOOL
-scg_yes(msg)
-	char	*msg;
+BOOL
+scg_yes(char *msg)
 {
 	char okbuf[10];
 
@@ -355,9 +336,8 @@
 }
 
 #ifdef	nonono
-LOCAL void
-scg_sighandler(sig)
-	int	sig;
+static void
+scg_sighandler(int sig)
 {
 	js_printf("\n");
 	if (scsi_running) {
@@ -376,9 +356,8 @@
  * Do error checking and reporting depending on the values of
  * scgp->verbose, scgp->debug and scgp->silent.
  */
-EXPORT int
-scg_cmd(scgp)
-	SCSI	*scgp;
+int
+scg_cmd(SCSI *scgp)
 {
 		int		ret;
 	register struct	scg_cmd	*scmd = scgp->scmd;
@@ -449,9 +428,8 @@
  * Fill the head of verbose printing into the SCSI error buffer.
  * Action depends on SCSI verbose status.
  */
-EXPORT void
-scg_vhead(scgp)
-	SCSI	*scgp;
+void
+scg_vhead(SCSI *scgp)
 {
 	scgp->errptr += scg_svhead(scgp, scgp->errptr, scg_errrsize(scgp));
 }
@@ -460,11 +438,8 @@
  * Fill the head of verbose printing into a buffer.
  * Action depends on SCSI verbose status.
  */
-EXPORT int
-scg_svhead(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_svhead(SCSI *scgp, char *buf, int maxcnt)
 {
 	register char	*p = buf;
 	register int	amt;
@@ -503,9 +478,8 @@
  * Fill the tail of verbose printing into the SCSI error buffer.
  * Action depends on SCSI verbose status.
  */
-EXPORT int
-scg_vtail(scgp)
-	SCSI	*scgp;
+int
+scg_vtail(SCSI *scgp)
 {
 	int	ret;
 
@@ -517,12 +491,8 @@
  * Fill the tail of verbose printing into a buffer.
  * Action depends on SCSI verbose status.
  */
-EXPORT int
-scg_svtail(scgp, retp, buf, maxcnt)
-	SCSI	*scgp;
-	int	*retp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_svtail(SCSI *scgp, int *retp, char *buf, int maxcnt)
 {
 	register char	*p = buf;
 	register int	amt;
@@ -575,9 +545,8 @@
  * Set up SCSI error buffer with verbose print data.
  * Action depends on SCSI verbose status.
  */
-EXPORT void
-scg_vsetup(scgp)
-	SCSI	*scgp;
+void
+scg_vsetup(SCSI *scgp)
 {
 	scg_vhead(scgp);
 	scg_vtail(scgp);
@@ -587,9 +556,8 @@
  * Return the residual DMA count for last command.
  * If this count is < 0, then a DMA overrun occured.
  */
-EXPORT int
-scg_getresid(scgp)
-	SCSI	*scgp;
+int
+scg_getresid(SCSI *scgp)
 {
 	return (scgp->scmd->resid);
 }
@@ -597,9 +565,8 @@
 /*
  * Return the actual DMA count for last command.
  */
-EXPORT int
-scg_getdmacnt(scgp)
-	SCSI	*scgp;
+int
+scg_getdmacnt(SCSI *scgp)
 {
 	register struct scg_cmd *scmd = scgp->scmd;
 
@@ -612,9 +579,8 @@
 /*
  * Test if last SCSI command got an error.
  */
-EXPORT BOOL
-scg_cmd_err(scgp)
-	SCSI	*scgp;
+BOOL
+scg_cmd_err(SCSI *scgp)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 
@@ -641,9 +607,8 @@
  *
  * to SCSI errfile.
  */
-EXPORT void
-scg_printerr(scgp)
-	SCSI	*scgp;
+void
+scg_printerr(SCSI *scgp)
 {
 	scg_fprinterr(scgp, (FILE *)scgp->errfile);
 }
@@ -661,10 +626,8 @@
  *
  * to a file.
  */
-EXPORT void
-scg_fprinterr(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+void
+scg_fprinterr(SCSI *scgp, FILE *f)
 {
 	char	errbuf[SCSI_ERRSTR_SIZE];
 	int	amt;
@@ -689,11 +652,8 @@
  *
  * into a buffer.
  */
-EXPORT int
-scg_sprinterr(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_sprinterr(SCSI *scgp, char *buf, int maxcnt)
 {
 	int	amt;
 	int	osilent = scgp->silent;
@@ -718,11 +678,8 @@
  *
  * into a buffer.
  */
-EXPORT int
-scg__sprinterr(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg__sprinterr(SCSI *scgp, char *buf, int maxcnt)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 	register char		*err;
@@ -794,9 +751,8 @@
  *
  * print the SCSI Command descriptor block to XXX stderr.
  */
-EXPORT void
-scg_printcdb(scgp)
-	SCSI	*scgp;
+void
+scg_printcdb(SCSI *scgp)
 {
 	scg_prbytes("CDB: ", scgp->scmd->cdb.cmd_cdb, scgp->scmd->cdb_len);
 }
@@ -804,11 +760,8 @@
 /*
  * print the SCSI Command descriptor block into a buffer.
  */
-EXPORT int
-scg_sprintcdb(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_sprintcdb(SCSI *scgp, char *buf, int maxcnt)
 {
 	int	cnt;
 
@@ -825,9 +778,8 @@
  *
  * print the SCSI send data to stderr.
  */
-EXPORT void
-scg_printwdata(scgp)
-	SCSI	*scgp;
+void
+scg_printwdata(SCSI *scgp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -843,11 +795,8 @@
 /*
  * print the SCSI send data into a buffer.
  */
-EXPORT int
-scg_sprintwdata(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_sprintwdata(SCSI *scgp, char *buf, int maxcnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 	register char		*p = buf;
@@ -876,9 +825,8 @@
  *
  * print the SCSI received data to stderr.
  */
-EXPORT void
-scg_printrdata(scgp)
-	SCSI	*scgp;
+void
+scg_printrdata(SCSI *scgp)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 	register int		trcnt = scg_getdmacnt(scgp);
@@ -896,11 +844,8 @@
 /*
  * print the SCSI received data into a buffer.
  */
-EXPORT int
-scg_sprintrdata(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_sprintrdata(SCSI *scgp, char *buf, int maxcnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 	register char		*p = buf;
@@ -932,9 +877,8 @@
  *
  * print the SCSI timings and (depending on verbose) received data to stderr.
  */
-EXPORT void
-scg_printresult(scgp)
-	SCSI	*scgp;
+void
+scg_printresult(SCSI *scgp)
 {
 	js_fprintf(stderr, "cmd finished after %ld.%03lds timeout %ds\n",
 		(long)scgp->cmdstop->tv_sec,
@@ -948,11 +892,8 @@
 /*
  * print the SCSI timings and (depending on verbose) received data into a buffer.
  */
-EXPORT int
-scg_sprintresult(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_sprintresult(SCSI *scgp, char *buf, int maxcnt)
 {
 	register char		*p = buf;
 	register int		amt;
@@ -980,9 +921,8 @@
  *
  * print the SCSI status byte in human readable form to the SCSI error file.
  */
-EXPORT void
-scg_printstatus(scgp)
-	SCSI	*scgp;
+void
+scg_printstatus(SCSI *scgp)
 {
 	char	errbuf[SCSI_ERRSTR_SIZE];
 	int	amt;
@@ -997,11 +937,8 @@
 /*
  * print the SCSI status byte in human readable form into a buffer.
  */
-EXPORT int
-scg_sprintstatus(scgp, buf, maxcnt)
-	SCSI	*scgp;
-	char	*buf;
-	int	maxcnt;
+int
+scg_sprintstatus(SCSI *scgp, char *buf, int maxcnt)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 		char	*err;
@@ -1055,12 +992,8 @@
 /*
  * print some bytes in hex to a file.
  */
-EXPORT void
-scg_fprbytes(f, s, cp, n)
-		FILE	*f;
-		char	*s;
-	register Uchar	*cp;
-	register int	n;
+void
+scg_fprbytes(FILE *f, char *s, register Uchar *cp, register int n)
 {
 	js_fprintf(f, "%s", s);
 	while (--n >= 0)
@@ -1071,12 +1004,8 @@
 /*
  * print some bytes in ascii to a file.
  */
-EXPORT void
-scg_fprascii(f, s, cp, n)
-		FILE	*f;
-		char	*s;
-	register Uchar	*cp;
-	register int	n;
+void
+scg_fprascii(FILE *f, char *s, register Uchar *cp, register int n)
 {
 	register int	c;
 
@@ -1096,11 +1025,8 @@
  *
  * print some bytes in hex to stderr.
  */
-EXPORT void
-scg_prbytes(s, cp, n)
-		char	*s;
-	register Uchar	*cp;
-	register int	n;
+void
+scg_prbytes(char *s, register Uchar *cp, register int n)
 {
 	scg_fprbytes(stderr, s, cp, n);
 }
@@ -1110,11 +1036,8 @@
  *
  * print some bytes in ascii to stderr.
  */
-EXPORT void
-scg_prascii(s, cp, n)
-		char	*s;
-	register Uchar	*cp;
-	register int	n;
+void
+scg_prascii(char *s, register Uchar *cp, register int n)
 {
 	scg_fprascii(stderr, s, cp, n);
 }
@@ -1122,13 +1045,8 @@
 /*
  * print some bytes in hex into a buffer.
  */
-EXPORT int
-scg_sprbytes(buf, maxcnt, s, cp, n)
-		char	*buf;
-		int	maxcnt;
-		char	*s;
-	register Uchar	*cp;
-	register int	n;
+int
+scg_sprbytes(char *buf, int maxcnt, char *s, register Uchar *cp, register int n)
 {
 	register char	*p = buf;
 	register int	amt;
@@ -1156,13 +1074,8 @@
 /*
  * print some bytes in ascii into a buffer.
  */
-EXPORT int
-scg_sprascii(buf, maxcnt, s, cp, n)
-		char	*buf;
-		int	maxcnt;
-		char	*s;
-	register Uchar	*cp;
-	register int	n;
+int
+scg_sprascii(char *buf, int maxcnt, char *s, register Uchar *cp, register int n)
 {
 	register char	*p = buf;
 	register int	amt;
@@ -1195,11 +1108,8 @@
 /*
  * print the SCSI sense data for last command in hex to a file.
  */
-EXPORT void
-scg_fprsense(f, cp, n)
-	FILE	*f;
-	Uchar	*cp;
-	int	n;
+void
+scg_fprsense(FILE *f, Uchar *cp, int n)
 {
 	scg_fprbytes(f, "Sense Bytes:", cp, n);
 }
@@ -1209,10 +1119,8 @@
  *
  * print the SCSI sense data for last command in hex to stderr.
  */
-EXPORT void
-scg_prsense(cp, n)
-	Uchar	*cp;
-	int	n;
+void
+scg_prsense(Uchar *cp, int n)
 {
 	scg_fprsense(stderr, cp, n);
 }
@@ -1220,12 +1128,8 @@
 /*
  * print the SCSI sense data for last command in hex into a buffer.
  */
-EXPORT int
-scg_sprsense(buf, maxcnt, cp, n)
-	char	*buf;
-	int	maxcnt;
-	Uchar	*cp;
-	int	n;
+int
+scg_sprsense(char *buf, int maxcnt, Uchar *cp, int n)
 {
 	return (scg_sprbytes(buf, maxcnt, "Sense Bytes:", cp, n));
 }
@@ -1233,9 +1137,8 @@
 /*
  * Return the SCSI status byte for last command.
  */
-EXPORT int
-scg_cmd_status(scgp)
-	SCSI	*scgp;
+int
+scg_cmd_status(SCSI *scgp)
 {
 	struct scg_cmd	*cp = scgp->scmd;
 	int		cmdstatus = *(Uchar *)&cp->scb;
@@ -1246,9 +1149,8 @@
 /*
  * Return the SCSI sense key for last command.
  */
-EXPORT int
-scg_sense_key(scgp)
-	SCSI	*scgp;
+int
+scg_sense_key(SCSI *scgp)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 	int	key = -1;
@@ -1264,9 +1166,8 @@
 /*
  * Return all the SCSI sense table last command.
  */
-EXPORT unsigned char *
-scg_sense_table(scgp)
-	SCSI	*scgp;
+unsigned char *
+scg_sense_table(SCSI *scgp)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 
@@ -1281,9 +1182,8 @@
 /*
  * Return the SCSI sense code for last command.
  */
-EXPORT int
-scg_sense_code(scgp)
-	SCSI	*scgp;
+int
+scg_sense_code(SCSI *scgp)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 	int	code = -1;
@@ -1301,9 +1201,8 @@
 /*
  * Return the SCSI sense qualifier for last command.
  */
-EXPORT int
-scg_sense_qual(scgp)
-	SCSI	*scgp;
+int
+scg_sense_qual(SCSI *scgp)
 {
 	register struct scg_cmd *cp = scgp->scmd;
 
@@ -1319,10 +1218,8 @@
 /*
  * Print the device type from the SCSI inquiry buffer to file.
  */
-EXPORT void
-scg_fprintdev(f, ip)
-		FILE	*f;
-	struct	scsi_inquiry *ip;
+void
+scg_fprintdev(FILE *f, struct scsi_inquiry *ip)
 {
 	if (ip->removable)
 		js_fprintf(f, "Removable ");
@@ -1409,9 +1306,8 @@
 /*
  * Print the device type from the SCSI inquiry buffer to stdout.
  */
-EXPORT void
-scg_printdev(ip)
-	struct	scsi_inquiry *ip;
+void
+scg_printdev(struct scsi_inquiry *ip)
 {
 	scg_fprintdev(stdout, ip);
 }
@@ -1422,24 +1318,13 @@
  * print into the SCSI error buffer, adjust the next write pointer.
  */
 /* VARARGS2 */
-EXPORT int
-#ifdef	PROTOTYPES
+int
 scg_printf(SCSI *scgp, const char *form, ...)
-#else
-scg_printf(scgp, form, va_alist)
-	SCSI	*scgp;
-	char	*form;
-	va_dcl
-#endif
 {
 	int	cnt;
 	va_list	args;
 
-#ifdef	PROTOTYPES
 	va_start(args, form);
-#else
-	va_start(args);
-#endif
 	cnt = js_snprintf(scgp->errptr, scg_errrsize(scgp), "%r", form, args);
 	va_end(args);
 
@@ -1455,9 +1340,8 @@
  * Flush the SCSI error buffer to SCSI errfile.
  * Clear error buffer after flushing.
  */
-EXPORT int
-scg_errflush(scgp)
-	SCSI	*scgp;
+int
+scg_errflush(SCSI *scgp)
 {
 	if (scgp->errfile == NULL)
 		return (0);
@@ -1469,10 +1353,8 @@
  * Flush the SCSI error buffer to a file.
  * Clear error buffer after flushing.
  */
-EXPORT int
-scg_errfflush(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+int
+scg_errfflush(SCSI *scgp, FILE *f)
 {
 	int	cnt;
 

Modified: nonameyet/branches/cleanup/libunls/nls.h
===================================================================
--- nonameyet/branches/cleanup/libunls/nls.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libunls/nls.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -83,48 +83,48 @@
 #define	CONFIG_NLS_CODEPAGE_10079
 #define	CONFIG_NLS_CODEPAGE_10081
 
-extern int init_unls_iso8859_1	__PR((void));
-extern int init_unls_iso8859_2	__PR((void));
-extern int init_unls_iso8859_3	__PR((void));
-extern int init_unls_iso8859_4	__PR((void));
-extern int init_unls_iso8859_5	__PR((void));
-extern int init_unls_iso8859_6	__PR((void));
-extern int init_unls_iso8859_7	__PR((void));
-extern int init_unls_iso8859_8	__PR((void));
-extern int init_unls_iso8859_9	__PR((void));
-extern int init_unls_iso8859_14	__PR((void));
-extern int init_unls_iso8859_15	__PR((void));
-extern int init_unls_cp437	__PR((void));
-extern int init_unls_cp737	__PR((void));
-extern int init_unls_cp775	__PR((void));
-extern int init_unls_cp850	__PR((void));
-extern int init_unls_cp852	__PR((void));
-extern int init_unls_cp855	__PR((void));
-extern int init_unls_cp857	__PR((void));
-extern int init_unls_cp860	__PR((void));
-extern int init_unls_cp861	__PR((void));
-extern int init_unls_cp862	__PR((void));
-extern int init_unls_cp863	__PR((void));
-extern int init_unls_cp864	__PR((void));
-extern int init_unls_cp865	__PR((void));
-extern int init_unls_cp866	__PR((void));
-extern int init_unls_cp869	__PR((void));
-extern int init_unls_cp874	__PR((void));
-extern int init_unls_cp1250	__PR((void));
-extern int init_unls_cp1251	__PR((void));
-extern int init_unls_koi8_r	__PR((void));
-extern int init_unls_koi8_u	__PR((void));
+extern int init_unls_iso8859_1(void);
+extern int init_unls_iso8859_2(void);
+extern int init_unls_iso8859_3(void);
+extern int init_unls_iso8859_4(void);
+extern int init_unls_iso8859_5(void);
+extern int init_unls_iso8859_6(void);
+extern int init_unls_iso8859_7(void);
+extern int init_unls_iso8859_8(void);
+extern int init_unls_iso8859_9(void);
+extern int init_unls_iso8859_14(void);
+extern int init_unls_iso8859_15(void);
+extern int init_unls_cp437(void);
+extern int init_unls_cp737(void);
+extern int init_unls_cp775(void);
+extern int init_unls_cp850(void);
+extern int init_unls_cp852(void);
+extern int init_unls_cp855(void);
+extern int init_unls_cp857(void);
+extern int init_unls_cp860(void);
+extern int init_unls_cp861(void);
+extern int init_unls_cp862(void);
+extern int init_unls_cp863(void);
+extern int init_unls_cp864(void);
+extern int init_unls_cp865(void);
+extern int init_unls_cp866(void);
+extern int init_unls_cp869(void);
+extern int init_unls_cp874(void);
+extern int init_unls_cp1250(void);
+extern int init_unls_cp1251(void);
+extern int init_unls_koi8_r(void);
+extern int init_unls_koi8_u(void);
 
-extern int init_unls_cp10000	__PR((void));
-extern int init_unls_cp10006	__PR((void));
-extern int init_unls_cp10007	__PR((void));
-extern int init_unls_cp10029	__PR((void));
-extern int init_unls_cp10079	__PR((void));
-extern int init_unls_cp10081	__PR((void));
-extern int init_unls_file	__PR((char * name));
+extern int init_unls_cp10000(void);
+extern int init_unls_cp10006(void);
+extern int init_unls_cp10007(void);
+extern int init_unls_cp10029(void);
+extern int init_unls_cp10079(void);
+extern int init_unls_cp10081(void);
+extern int init_unls_file(char *name);
 
 #ifdef USE_ICONV
-extern int init_nls_iconv     __PR((char * name));
+extern int init_nls_iconv(char *name);
 #endif
 
 #endif	/* _NLS_H */

Modified: nonameyet/branches/cleanup/libunls/nls_base.c
===================================================================
--- nonameyet/branches/cleanup/libunls/nls_base.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libunls/nls_base.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -52,8 +52,7 @@
 static struct unls_table *tables = (struct unls_table *) NULL;
 
 int
-register_unls(unls)
-	struct unls_table	*unls;
+register_unls(struct unls_table *unls)
 {
 	struct unls_table ** tmp = &tables;
 
@@ -73,8 +72,7 @@
 }
 
 int
-unregister_unls(unls)
-	struct unls_table	*unls;
+unregister_unls(struct unls_table *unls)
 {
 	struct unls_table ** tmp = &tables;
 
@@ -89,8 +87,7 @@
 }
 
 struct unls_table *
-find_unls(charset)
-	char	*charset;
+find_unls(char *charset)
 {
 	struct unls_table *unls = tables;
 	while (unls) {
@@ -112,8 +109,7 @@
 }
 
 struct unls_table *
-load_unls(charset)
-	char	*charset;
+load_unls(char *charset)
 {
 	struct unls_table *unls;
 
@@ -126,8 +122,7 @@
 }
 
 void
-unload_unls(nls)
-	struct unls_table	*nls;
+unload_unls(struct unls_table *nls)
 {
 }
 

Modified: nonameyet/branches/cleanup/libunls/nls_file.c
===================================================================
--- nonameyet/branches/cleanup/libunls/nls_file.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libunls/nls_file.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -50,12 +50,10 @@
 
 #define	NUM	256
 
-static void	free_mem __PR((struct unls_unicode *, unsigned char **));
+static void	free_mem(struct unls_unicode *, unsigned char **);
 
 static void
-free_mem(charset2uni, page_uni2charset)
-	struct unls_unicode *charset2uni;
-	unsigned char **page_uni2charset;
+free_mem(struct unls_unicode *charset2uni, unsigned char **page_uni2charset)
 {
 	int	i;
 
@@ -73,8 +71,7 @@
 }
 
 int
-init_unls_file(filename)
-	char	*filename;
+init_unls_file(char *filename)
 {
 	FILE	*fp;
 	struct unls_unicode *charset2uni = NULL;

Modified: nonameyet/branches/cleanup/libunls/nls_iconv.c
===================================================================
--- nonameyet/branches/cleanup/libunls/nls_iconv.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/libunls/nls_iconv.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -49,8 +49,8 @@
 #include "nls.h"
 #include <iconv.h>
 
-static void	inc_use_count	__PR((void));
-static void	dec_use_count	__PR((void));
+static void	inc_use_count(void);
+static void	dec_use_count(void);
 
 
 static void
@@ -66,8 +66,7 @@
 }
 
 int
-init_nls_iconv(charset)
-	char	*charset;
+init_nls_iconv(char *charset)
 {
 	iconv_t iconv_d;  /* iconv conversion descriptor */
 	struct unls_table *table;

Modified: nonameyet/branches/cleanup/mkisofs/apple.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/apple.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/apple.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -71,48 +71,48 @@
 
 /* routines for getting HFS names and info */
 #ifndef	HAVE_STRCASECMP
-static int	strcasecmp	__PR((const char *s1, const char *s2));
+static int	strcasecmp(const char *s1, const char *s2);
 #endif
-static int	get_none_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_none_info	__PR((char *, char *, dir_ent *, int));
-static int	get_cap_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_cap_info	__PR((char *, char *, dir_ent *, int));
-static int	get_es_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_es_info	__PR((char *, char *, dir_ent *, int));
-static int	get_dbl_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_dbl_info	__PR((char *, char *, dir_ent *, int));
-static int	get_mb_info	__PR((char *, char *, dir_ent *, int));
-static int	get_sgl_info	__PR((char *, char *, dir_ent *, int));
-static int	get_fe_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_fe_info	__PR((char *, char *, dir_ent *, int));
-static int	get_sgi_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_sgi_info	__PR((char *, char *, dir_ent *, int));
-static int	get_sfm_info	__PR((char *, char *, dir_ent *, int));
+static int	get_none_dir(char *, char *, dir_ent *, int);
+static int	get_none_info(char *, char *, dir_ent *, int);
+static int	get_cap_dir(char *, char *, dir_ent *, int);
+static int	get_cap_info(char *, char *, dir_ent *, int);
+static int	get_es_dir(char *, char *, dir_ent *, int);
+static int	get_es_info(char *, char *, dir_ent *, int);
+static int	get_dbl_dir(char *, char *, dir_ent *, int);
+static int	get_dbl_info(char *, char *, dir_ent *, int);
+static int	get_mb_info(char *, char *, dir_ent *, int);
+static int	get_sgl_info(char *, char *, dir_ent *, int);
+static int	get_fe_dir(char *, char *, dir_ent *, int);
+static int	get_fe_info(char *, char *, dir_ent *, int);
+static int	get_sgi_dir(char *, char *, dir_ent *, int);
+static int	get_sgi_info(char *, char *, dir_ent *, int);
+static int	get_sfm_info(char *, char *, dir_ent *, int);
 
 #ifdef IS_MACOS_X
-static int	get_xhfs_dir	__PR((char *, char *, dir_ent *, int));
-static int	get_xhfs_info	__PR((char *, char *, dir_ent *, int));
+static int	get_xhfs_dir(char *, char *, dir_ent *, int);
+static int	get_xhfs_info(char *, char *, dir_ent *, int);
 #else
 #define	get_xhfs_dir	get_none_dir
 #define	get_xhfs_info	get_none_info
 #endif /* IS_MACOS_X */
 
-static void	set_ct		__PR((hfsdirent *, char *, char *));
-static void	set_Dinfo	__PR((byte *, hfsdirent *));
-static void	set_Finfo	__PR((byte *, hfsdirent *));
-static void	cstrncpy	__PR((char *, char *, int));
-static unsigned char dehex	__PR((char));
-static unsigned char hex2char	__PR((char *));
-static void	hstrncpy	__PR((unsigned char *, char *, int));
-static int	read_info_file	__PR((char *, void *, int));
+static void	set_ct(hfsdirent *, char *, char *);
+static void	set_Dinfo(byte *, hfsdirent *);
+static void	set_Finfo(byte *, hfsdirent *);
+static void	cstrncpy(char *, char *, int);
+static unsigned char dehex(char);
+static unsigned char hex2char(char *);
+static void	hstrncpy(unsigned char *, char *, int);
+static int	read_info_file(char *, void *, int);
 
 /*static unsigned short	calc_mb_crc	__PR((unsigned char *, long, unsigned short));*/
-static struct hfs_info *get_hfs_fe_info	__PR((struct hfs_info *, char *));
-static struct hfs_info *get_hfs_sgi_info __PR((struct hfs_info *, char *));
-static struct hfs_info *match_key	__PR((struct hfs_info *, char *));
+static struct hfs_info *get_hfs_fe_info(struct hfs_info *, char *);
+static struct hfs_info *get_hfs_sgi_info(struct hfs_info *, char *);
+static struct hfs_info *match_key(struct hfs_info *, char *);
 
-static int	get_hfs_itype	__PR((char *, char *, char *));
-static void	map_ext		__PR((char *, char **, char **, short *, char *));
+static int	get_hfs_itype(char *, char *, char *);
+static void	map_ext(char *, char **, char **, short *, char *);
 
 static afpmap	**map;		/* list of mappings */
 static afpmap	*defmap;	/* the default mapping */
@@ -131,9 +131,9 @@
 	int	flags;	/* special flags */
 	char	*info;	/* finderinfo name */
 	char	*rsrc;	/* resource fork name */
-	int	(*get_info) __PR((char *, char *, dir_ent *, int)); /* finderinfo */
+	int	(*get_info)(char *, char *, dir_ent *, int); /* finderinfo */
 								    /*	function */
-	int	(*get_dir) __PR((char *, char *, dir_ent *, int));  /* directory */
+	int	(*get_dir)(char *, char *, dir_ent *, int);  /* directory */
 								    /* name */
 								    /* function */
 	char	*desc;	/* description */
@@ -216,9 +216,7 @@
 
 #ifndef	HAVE_STRCASECMP
 static int
-strcasecmp(s1, s2)
-	const char	*s1;
-	const char	*s2;
+strcasecmp(const char *s1, const char *s2)
 {
 	while (tolower(*s1) == tolower(*s2)) {
 		if (*s1 == 0)
@@ -237,10 +235,7 @@
  */
 
 static void
-set_ct(hfs_ent, c, t)
-	hfsdirent	*hfs_ent;
-	char		*c;
-	char		*t;
+set_ct(hfsdirent *hfs_ent, char *c, char *t)
 {
 	memset(hfs_ent->u.file.type, ' ', CT_SIZE);
 	memset(hfs_ent->u.file.creator, ' ', CT_SIZE);
@@ -258,10 +253,7 @@
  *	':' is replaced by '%' and string is terminated with '\0'
  */
 static void
-cstrncpy(t, f, c)
-	char		*t;
-	char		*f;
-	int		c;
+cstrncpy(char *t, char *f, int c)
 {
 	while (c-- && *f) {
 		switch (*f) {
@@ -286,15 +278,8 @@
  *
  *	Taken from linux/fs/hfs/trans.c by Paul H. Hargrove
  */
-#ifdef	PROTOTYPES
 static unsigned char
 dehex(char c)
-#else
-static unsigned char
-dehex(c)
-	char	c;
-
-#endif
 {
 	if ((c >= '0') && (c <= '9')) {
 		return (c - '0');
@@ -310,8 +295,7 @@
 }
 
 static unsigned char
-hex2char(s)
-	char		*s;
+hex2char(char *s)
 {
 	unsigned char	i1;
 	unsigned char	i2;
@@ -345,10 +329,7 @@
  *
  */
 static void
-hstrncpy(t, f, c)
-	unsigned char	*t;
-	char		*f;
-	int		c;
+hstrncpy(unsigned char *t, char *f, int c)
 {
 	unsigned char	o;
 
@@ -396,9 +377,7 @@
  *	set_Dinfo: set directory info
  */
 static void
-set_Dinfo(ptr, ent)
-	byte		*ptr;
-	hfsdirent	*ent;
+set_Dinfo(byte *ptr, hfsdirent *ent)
 {
 	Dinfo	*dinfo = (Dinfo *)ptr;
 
@@ -440,9 +419,7 @@
  *	set_Finfo: set file info
  */
 static void
-set_Finfo(ptr, ent)
-	byte		*ptr;
-	hfsdirent	*ent;
+set_Finfo(byte *ptr, hfsdirent *ent)
 {
 	Finfo	*finfo = (Finfo *)ptr;
 
@@ -469,11 +446,7 @@
  *	get_none_dir: ordinary Unix directory
  */
 static int
-get_none_dir(hname, dname, s_entry, ret)
-	char		*hname;
-	char		*dname;
-	dir_ent		*s_entry;
-	int		ret;
+get_none_dir(char *hname, char *dname, dir_ent *s_entry, int ret)
 {
 	/* just copy the given name */
 	hstrncpy((unsigned char *) (s_entry->hfs_ent->name),
@@ -486,11 +459,7 @@
  *	get_none_info: ordinary Unix file - try to map extension
  */
 static int
-get_none_info(hname, dname, s_entry, ret)
-	char		*hname;
-	char		*dname;
-	dir_ent		*s_entry;
-	int		ret;
+get_none_info(char *hname, char *dname, dir_ent *s_entry, int ret)
 {
 	char		*t,
 			*c;
@@ -511,10 +480,9 @@
  *			or directory
  */
 static int
-read_info_file(name, info, len)
-	char		*name;	/* finderinfo filename */
-	void		*info;	/* info buffer */
-	int		len;	/* length of above */
+read_info_file(char *name, /* finderinfo filename */
+					void *info, /* info buffer */
+					int len		/* length of above */)
 {
 	FILE		*fp;
 	int		num;
@@ -537,11 +505,10 @@
  *	get_cap_dir: get the CAP name for a directory
  */
 static int
-get_cap_dir(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_cap_dir(char *hname, /* whole path */ 
+				char *dname, /* this dir name */
+				dir_ent *s_entry, /* directory entry */ 
+				int ret)
 {
 	FileInfo	info;		/* finderinfo struct */
 	int		num = -1;	/* bytes read */
@@ -573,11 +540,10 @@
 **	get_cap_info:	get CAP finderinfo for a file
 */
 static int
-get_cap_info(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_cap_info(char *hname, /* whole path */
+				 char *dname, /* this dir name */
+				 dir_ent *s_entry, /* directory entry */
+				 int ret)
 {
 	FileInfo	info;		/* finderinfo struct */
 	int		num = -1;	/* bytes read */
@@ -636,11 +602,10 @@
  *	<psylvstr at interaccess.com>
  */
 static int
-get_es_dir(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_es_dir(char *hname, /* whole path */ 
+			  char *dname, /* this dir name */
+			  dir_ent *s_entry, /* directory entry */
+			  int ret)
 {
 	es_FileInfo	*einfo;		/* EtherShare info struct */
 	us_FileInfo	*uinfo;		/* UShare info struct */
@@ -696,11 +661,10 @@
  *	<psylvstr at interaccess.com>
  */
 static int
-get_es_info(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_es_info(char *hname, /* whole path */
+				char *dname, /* this dir name */
+				dir_ent *s_entry, /* directory entry */
+				int ret)
 {
 	es_FileInfo	*einfo;		/* EtherShare info struct */
 	us_FileInfo	*uinfo;		/* UShare info struct */
@@ -789,17 +753,8 @@
  *   Modified by Jim Van Verth to use the magic array for efficiency.
  */
 #ifdef	__used__
-#ifdef	PROTOTYPES
 static unsigned short
 calc_mb_crc(unsigned char *p, long len, unsigned short seed)
-#else
-static unsigned short
-calc_mb_crc(p, len, seed)
-	unsigned char	*p;
-	long		len;
-	unsigned short	seed;
-
-#endif
 {
 	unsigned short	hold;	/* crc computed so far */
 	long		i;	/* index into data */
@@ -816,11 +771,10 @@
 #endif	/* __used__ */
 
 static int
-get_mb_info(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_mb_info(char *hname, /* whole path */
+				char *dname, /* this dir name */
+				dir_ent *s_entry, /* directory entry */
+				int ret)
 {
 	mb_info		*info;		/* finderinfo struct */
 	char		*c;
@@ -954,11 +908,10 @@
  *	Based on code from cvt2cap.c (c) May 1988, Paul Campbell
  */
 static int
-get_dbl_dir(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_dbl_dir(char *hname, /* whole path */
+				char *dname, /* this dir name */
+				dir_ent *s_entry, /* directory entry */
+				int ret)
 {
 	FileInfo	info;		/* finderinfo struct */
 	a_hdr		*hp;
@@ -1087,11 +1040,10 @@
  *	Based on code from cvt2cap.c (c) May 1988, Paul Campbell
  */
 static int
-get_dbl_info(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_dbl_info(char *hname, /* whole path */
+				 char *dname, /* this dir name */
+				 dir_ent *s_entry, /* directory entry */
+				 int ret)
 {
 	FileInfo	info;		/* finderinfo struct */
 	a_hdr		*hp;
@@ -1253,11 +1205,10 @@
  *	Based on code from cvt2cap.c (c) May 1988, Paul Campbell
  */
 static int
-get_sgl_info(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_sgl_info(char *hname, /* whole path */
+				 char *dname, /* this dir name */
+				 dir_ent *s_entry, /* directory entry */
+				 int ret)
 {
 	FileInfo	*info = 0;	/* finderinfo struct */
 	a_hdr		*hp;
@@ -1419,9 +1370,7 @@
  *	with v2.2 and above.
  */
 static struct hfs_info *
-get_hfs_fe_info(hfs_info, name)
-	struct hfs_info	*hfs_info;
-	char		*name;
+get_hfs_fe_info(struct hfs_info *hfs_info, char *name)
 {
 	FILE		*fp;
 	int		fe_num,
@@ -1520,9 +1469,7 @@
  *		file.
  */
 static struct hfs_info *
-get_hfs_sgi_info(hfs_info, name)
-	struct hfs_info	*hfs_info;
-	char		*name;
+get_hfs_sgi_info(struct hfs_info *hfs_info, char *name)
 {
 	FILE		*fp;
 	sgi_info	info;
@@ -1556,8 +1503,7 @@
  *	del_hfs_info: delete the info list and recover memory
  */
 void
-del_hfs_info(hfs_info)
-	struct hfs_info	*hfs_info;
+del_hfs_info(struct hfs_info *hfs_info)
 {
 	struct hfs_info	*hfs_info1;
 
@@ -1578,10 +1524,7 @@
  *		as the key
  */
 static struct hfs_info *
-match_key(hfs_info, key)
-	struct hfs_info	*hfs_info;
-	char		*key;
-
+match_key(struct hfs_info *hfs_info, char *key)
 {
 	while (hfs_info) {
 		if (strcasecmp(key, hfs_info->keyname) == 0)
@@ -1598,11 +1541,10 @@
  *	base on probing with od ...
  */
 static int
-get_fe_dir(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_fe_dir(char *hname, /* whole path */
+			  char *dname, /* this dir name */
+			  dir_ent *s_entry, /* directory entry */
+			  int ret)
 {
 	struct hfs_info	*hfs_info;
 	hfsdirent	*hfs_ent = s_entry->hfs_ent;
@@ -1640,11 +1582,10 @@
  *	<mrwesq at earthlink.net>
  */
 static int
-get_fe_info(hname, dname, s_entry, ret)
-	char	*hname;		/* whole path */
-	char	*dname;		/* this dir name */
-	dir_ent	*s_entry;	/* directory entry */
-	int	ret;
+get_fe_info(char *hname, /* whole path */
+			   char *dname, /* this dir name */
+			   dir_ent *s_entry, /* directory entry */
+			   int ret)
 {
 	struct hfs_info	*hfs_info;
 	hfsdirent	*hfs_ent = s_entry->hfs_ent;
@@ -1708,11 +1649,10 @@
  *	base on probing with od ...
  */
 static int
-get_sgi_dir(hname, dname, s_entry, ret)
-	char	*hname;		/* whole path */
-	char	*dname;		/* this dir name */
-	dir_ent	*s_entry;	/* directory entry */
-	int	ret;
+get_sgi_dir(char *hname, /* whole path */
+			   char *dname, /* this dir name */
+			   dir_ent *s_entry, /* directory entry */
+			   int ret)
 {
 	struct hfs_info	*hfs_info;
 	hfsdirent	*hfs_ent = s_entry->hfs_ent;
@@ -1751,11 +1691,10 @@
  *	base on probing with od ...
  */
 static int
-get_sgi_info(hname, dname, s_entry, ret)
-	char	*hname;		/* whole path */
-	char	*dname;		/* this dir name */
-	dir_ent	*s_entry;	/* directory entry */
-	int	ret;
+get_sgi_info(char *hname, /* whole path */
+			    char *dname, /* this dir name */
+			    dir_ent *s_entry, /* directory entry */
+			    int ret)
 {
 	struct hfs_info	*hfs_info;
 	hfsdirent	*hfs_ent = s_entry->hfs_ent;
@@ -1804,11 +1743,10 @@
 static byte	sfm_version[4] = {0x00, 0x00, 0x01, 0x00};
 
 static int
-get_sfm_info(hname, dname, s_entry, ret)
-	char	*hname;		/* whole path */
-	char	*dname;		/* this dir name */
-	dir_ent	*s_entry;	/* directory entry */
-	int	ret;
+get_sfm_info(char *hname, /* whole path */
+			    char *dname, /* this dir name */
+			    dir_ent *s_entry, /* directory entry */
+			    int ret)
 {
 	sfm_info	info;	/* finderinfo struct */
 	int		num = -1; /* bytes read */
@@ -1851,11 +1789,10 @@
  *	The file name here is the pseudo name for the resource fork
  */
 static int
-get_xhfs_dir(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_xhfs_dir(char *hname, /* whole path */
+			    char *dname, /* this dir name */
+			    dir_ent *s_entry, /* directory entry */
+			    int ret)
 {
 	int		err;
 	hfsdirent	*hfs_ent = s_entry->hfs_ent;
@@ -1917,11 +1854,10 @@
  *	The file name here is the pseudo name for the resource fork
  */
 static int
-get_xhfs_info(hname, dname, s_entry, ret)
-	char		*hname;		/* whole path */
-	char		*dname;		/* this dir name */
-	dir_ent		*s_entry;	/* directory entry */
-	int		ret;
+get_xhfs_info(char *hname, /* whole path */
+			     char *dname, /* this dir name */
+			     dir_ent *s_entry, /* directory entry */
+			     int ret)
 {
 	int		err;
 	hfsdirent	*hfs_ent = s_entry->hfs_ent;
@@ -2005,10 +1941,7 @@
  *	get_hfs_itype: get the type of HFS info for a file
  */
 static int
-get_hfs_itype(wname, dname, htmp)
-	char	*wname;
-	char	*dname;
-	char	*htmp;
+get_hfs_itype(char *wname, char *dname, char *htmp)
 {
 	int	wlen,
 		i;
@@ -2062,8 +1995,7 @@
  *	set_root_info: set the root folder hfs_ent from given file
  */
 void
-set_root_info(name)
-	char	*name;
+set_root_info(char *name)
 {
 	dir_ent		*s_entry;
 	hfsdirent	*hfs_ent;
@@ -2093,10 +2025,7 @@
  *	get_hfs_dir: set the HFS directory name
  */
 int
-get_hfs_dir(wname, dname, s_entry)
-	char	*wname;
-	char	*dname;
-	dir_ent	*s_entry;
+get_hfs_dir(char *wname, char *dname, dir_ent *s_entry)
 {
 	int	type;
 
@@ -2113,10 +2042,7 @@
  *	get_hfs_info: set the HFS info for a file
  */
 int
-get_hfs_info(wname, dname, s_entry)
-	char	*wname;
-	char	*dname;
-	dir_ent	*s_entry;
+get_hfs_info(char *wname, char *dname, dir_ent *s_entry)
 {
 	int	type,
 		wlen,
@@ -2186,10 +2112,7 @@
  *	the 'info' filename is OK ...
  */
 int
-get_hfs_rname(wname, dname, rname)
-	char	*wname;
-	char	*dname;
-	char	*rname;
+get_hfs_rname(char *wname, char *dname, char *rname)
 {
 	int	wlen,
 		type,
@@ -2296,8 +2219,7 @@
  *		     These files/directories are processed later ...
  */
 int
-hfs_exclude(d_name)
-	char	*d_name;
+hfs_exclude(char *d_name)
 {
 	/* we don't exclude "." and ".." */
 	if (strcmp(d_name, ".") == 0)
@@ -2427,8 +2349,7 @@
  *
  */
 void
-print_hfs_info(s_entry)
-	dir_ent	*s_entry;
+print_hfs_info(dir_ent *s_entry)
 {
 	fprintf(stderr, "Name: %s\n", s_entry->whole_name);
 	fprintf(stderr, "\tFile type: %s\n", hfs_types[s_entry->hfs_type].desc);
@@ -2443,17 +2364,8 @@
  *	hfs_init: sets up the mapping list from the afpfile as well
  *		 the default mapping (with or without) an afpfile
  */
-#ifdef	PROTOTYPES
 void
 hfs_init(char *name, Ushort fdflags, Uint hfs_select)
-#else
-void
-hfs_init(name, fdflags, hfs_select)
-	char	*name;		/* afpfile name */
-	Ushort	fdflags;	/* default finder flags */
-	Uint	hfs_select;	/* select certain mac files */
-
-#endif
 {
 	FILE	*fp;		/* File pointer */
 	int	count = NUMMAP;	/* max number of entries */
@@ -2616,10 +2528,8 @@
 
 #ifdef USE_MAGIC
 static int
-try_map_magic(whole_name, type, creator)
-	char	*whole_name;
-	char	**type;		/* set type */
-	char	**creator;	/* set creator */
+try_map_magic(char *whole_name, char **type, /* set type */
+				  char **creator /* set creator */)
 {
 	const char * ret = magic_file(magic_state, whole_name);
 
@@ -2655,12 +2565,11 @@
  *	map_ext: map a files extension with the list to get type/creator
  */
 static void
-map_ext(name, type, creator, fdflags, whole_name)
-	char	*name;		/* filename */
-	char	**type;		/* set type */
-	char	**creator;	/* set creator */
-	short	*fdflags;	/* set finder flags */
-	char	*whole_name;
+map_ext(char *name, /* filename */
+		  char **type, /* set type */
+		  char **creator, /* set creator */
+		  short *fdflags, /* set finder flags */
+		  char *whole_name)
 {
 	int	i;		/* loop counter */
 	int	len;		/* filename length */
@@ -2727,8 +2636,7 @@
 }
 
 void
-delete_rsrc_ent(s_entry)
-	dir_ent	*s_entry;
+delete_rsrc_ent(dir_ent *s_entry)
 {
 	dir_ent	*s_entry1 = s_entry->next;
 
@@ -2764,8 +2672,7 @@
 #endif	/* APPLE_HYB */
 
 void
-perr(a)
-	char	*a;
+perr(char *a)
 {
 #ifdef	USE_LIBSCHILY
 	if (a)

Modified: nonameyet/branches/cleanup/mkisofs/apple.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/apple.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/apple.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -64,14 +64,14 @@
 } afpmap;
 
 /* from "data.h" - libhfs routines */
-unsigned long d_toutime	__PR((unsigned long));
-unsigned long d_dtoutime __PR((long));
-long d_getl		__PR((unsigned char *));
-short d_getw		__PR((unsigned char *));
+unsigned long d_toutime(unsigned long);
+unsigned long d_dtoutime(long);
+long d_getl(unsigned char *);
+short d_getw(unsigned char *);
 
 /* for libfile routines */
-int init_magic		__PR((char *));
-char * get_magic_match	__PR((const char *));
+int init_magic(char *);
+char * get_magic_match(const char *);
 
 typedef unsigned char byte;
 typedef unsigned char word[2];

Modified: nonameyet/branches/cleanup/mkisofs/apple_driver.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/apple_driver.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/apple_driver.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -44,13 +44,11 @@
 #include <mac_label.h>
 #include <schily.h>
 
-EXPORT	int	get_732	__PR((char *p));
-EXPORT	int	get_722	__PR((char *p));
-EXPORT	int	main	__PR((int argc, char **argv));
+int	get_732(char *p);
+int	get_722(char *p);
 
-EXPORT int
-get_732(p)
-	char	*p;
+int
+get_732(char *p)
 {
 	return ((p[3] & 0xff)
 		| ((p[2] & 0xff) << 8)
@@ -58,9 +56,8 @@
 		| ((p[0] & 0xff) << 24));
 }
 
-EXPORT int
-get_722(p)
-	char	*p;
+int
+get_722(char *p)
 {
 	return ((p[1] & 0xff)
 		| ((p[0] & 0xff) << 8));

Modified: nonameyet/branches/cleanup/mkisofs/boot-alpha.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/boot-alpha.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/boot-alpha.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -45,23 +45,21 @@
 #include <schily.h>
 #include "endianconv.h"
 
-        int     add_boot_alpha_filename   __PR((char *filename));
-static  int     boot_alpha_write          __PR((FILE *outfile));
+        int     add_boot_alpha_filename(char *filename);
+static  int     boot_alpha_write(FILE *outfile);
 static  char   *boot_file_name = NULL;
 
 #define BOOT_STRING "Linux/Alpha aboot for ISO filesystem."
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_alpha_filename(filename)
-    char *filename;
+extern int add_boot_alpha_filename(char *filename)
 {
     boot_file_name = filename;
     return 0;
 }
 
-static int boot_alpha_write(outfile)
-    FILE *outfile;
+static int boot_alpha_write(FILE *outfile)
 {
     unsigned long long boot_sector[256]; /* One (ISO) sector */
     unsigned long long sum = 0;

Modified: nonameyet/branches/cleanup/mkisofs/boot-hppa.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/boot-hppa.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/boot-hppa.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -53,13 +53,13 @@
 #include <schily.h>
 #include "endianconv.h"
 
-int     add_boot_hppa_cmdline     __PR((char *cmdline));
-int     add_boot_hppa_kernel_32   __PR((char *filename));
-int     add_boot_hppa_kernel_64   __PR((char *filename));
-int     add_boot_hppa_bootloader  __PR((char *filename));
-int     add_boot_hppa_ramdisk     __PR((char *filename));
+int     add_boot_hppa_cmdline(char *cmdline);
+int     add_boot_hppa_kernel_32(char *filename);
+int     add_boot_hppa_kernel_64(char *filename);
+int     add_boot_hppa_bootloader(char *filename);
+int     add_boot_hppa_ramdisk(char *filename);
 
-static  int     boot_hppa_write   __PR((FILE *outfile));
+static  int     boot_hppa_write(FILE *outfile);
 
 static  char   *hppa_cmdline = NULL;
 static  char   *hppa_kernel_32 = NULL;
@@ -69,8 +69,7 @@
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_hppa_cmdline(cmdline)
-    char *cmdline;
+extern int add_boot_hppa_cmdline(char *cmdline)
 {
     char *ptr = NULL;
     hppa_cmdline = strdup(cmdline);
@@ -86,8 +85,7 @@
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_hppa_kernel_32(filename)
-    char *filename;
+extern int add_boot_hppa_kernel_32(char *filename)
 {
     hppa_kernel_32 = filename;
     return 0;
@@ -95,8 +93,7 @@
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_hppa_kernel_64(filename)
-    char *filename;
+extern int add_boot_hppa_kernel_64(char *filename)
 {
     hppa_kernel_64 = filename;
     return 0;
@@ -104,8 +101,7 @@
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_hppa_bootloader(filename)
-    char *filename;
+extern int add_boot_hppa_bootloader(char *filename)
 {
     hppa_bootloader = filename;
     return 0;
@@ -113,16 +109,13 @@
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_hppa_ramdisk(filename)
-    char *filename;
+extern int add_boot_hppa_ramdisk(char *filename)
 {
     hppa_ramdisk = filename;
     return 0;
 }
 
-static void exit_fatal(type, filename)
-    char *type;
-    char *filename;
+static void exit_fatal(char *type, char *filename)
 {
 #ifdef	USE_LIBSCHILY
     comerrno(EX_BAD, "Uh oh, I can't find the %s '%s'!\n",
@@ -134,8 +127,7 @@
 #endif
 }
 
-static int boot_hppa_write(outfile)
-    FILE *outfile;
+static int boot_hppa_write(FILE *outfile)
 {
     unsigned char boot_sector[2048]; /* One (ISO) sector */
 	struct directory_entry	*boot_file;	/* Boot file we need to search for */
@@ -209,7 +201,3 @@
 }
 
 struct output_fragment hppaboot_desc = {NULL, oneblock_size, NULL, boot_hppa_write, "hppa boot block"};
-
-
-
-

Modified: nonameyet/branches/cleanup/mkisofs/boot-mips.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/boot-mips.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/boot-mips.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -195,9 +195,9 @@
 #include <schily.h>
 #include "endianconv.h"
 
-int     add_boot_mips_filename    __PR((char *filename));
+int     add_boot_mips_filename(char *filename);
 
-static  int     boot_mips_write   __PR((FILE *outfile));
+static  int     boot_mips_write(FILE *outfile);
 
 #define MAX_NAMES 15
 static char *boot_mips_filename[MAX_NAMES] =
@@ -214,8 +214,7 @@
 #define SECTORS_PER_TRACK	32
 #define BYTES_PER_SECTOR	512
 
-int add_boot_mips_filename(filename)
-    char *filename;
+int add_boot_mips_filename(char *filename)
 {
     if (boot_mips_num_files < MAX_NAMES)
     {
@@ -264,8 +263,7 @@
     return endptr;
 }
 
-static int boot_mips_write(outfile)
-    FILE *outfile;
+static int boot_mips_write(FILE *outfile)
 {
 	struct directory_entry	*boot_file;	/* Boot file we need to search for */
     unsigned long length = 0;

Modified: nonameyet/branches/cleanup/mkisofs/boot-mipsel.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/boot-mipsel.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/boot-mipsel.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -68,8 +68,8 @@
 #include <errno.h>
 #include <elf.h>
 
-int             add_boot_mipsel_filename  __PR((char *filename));
-static  int     boot_mipsel_write         __PR((FILE *outfile));
+int             add_boot_mipsel_filename(char *filename);
+static  int     boot_mipsel_write(FILE *outfile);
 
 static  char   *boot_file_name = NULL;
 
@@ -124,8 +124,7 @@
 
 /* Simple function: store the filename to be used later when we need
    to find the boot file */
-extern int add_boot_mipsel_filename(filename)
-    char *filename;
+extern int add_boot_mipsel_filename(char *filename)
 {
     boot_file_name = filename;
     return 0;
@@ -185,8 +184,7 @@
     return 0;
 }
 
-static int boot_mipsel_write(outfile)
-    FILE *outfile;
+static int boot_mipsel_write(FILE *outfile)
 {
     char sector[2048];
     struct dec_bootblock *bb = (struct dec_bootblock *)sector;
@@ -251,4 +249,3 @@
 }
 
 struct output_fragment mipselboot_desc = {NULL, oneblock_size, NULL, boot_mipsel_write, "mipsel boot block"};
-

Modified: nonameyet/branches/cleanup/mkisofs/boot.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/boot.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/boot.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -46,32 +46,32 @@
 
 extern	int	use_sunx86boot;
 
-LOCAL struct sun_label cd_label;
-LOCAL struct x86_label sx86_label;
-LOCAL struct pc_part	fdisk_part;
-LOCAL char	*boot_files[NDKMAP];	/* Change this for > 8 x86 parts */
+static struct sun_label cd_label;
+static struct x86_label sx86_label;
+static struct pc_part	fdisk_part;
+static char	*boot_files[NDKMAP];	/* Change this for > 8 x86 parts */
 
-LOCAL	void	init_sparc_label	__PR((void));
-LOCAL	void	init_sunx86_label	__PR((void));
-EXPORT	void	sparc_boot_label	__PR((char *label));
-EXPORT	void	sunx86_boot_label	__PR((char *label));
-EXPORT	void	scan_sparc_boot		__PR((char *files));
-EXPORT	void	scan_sunx86_boot	__PR((char *files));
-EXPORT	int	make_sun_label		__PR((void));
-EXPORT	int	make_sunx86_label	__PR((void));
-LOCAL	void	dup_sun_label		__PR((int part));
-LOCAL	int	sunboot_write		__PR((FILE *outfile));
-LOCAL	int	sunlabel_size		__PR((int starting_extent));
-LOCAL	int	sunlabel_write		__PR((FILE * outfile));
-LOCAL	int	genboot_size		__PR((int starting_extent));
-LOCAL	int	genboot_write		__PR((FILE * outfile));
+static	void	init_sparc_label(void);
+static	void	init_sunx86_label(void);
+void	sparc_boot_label(char *label);
+void	sunx86_boot_label(char *label);
+void	scan_sparc_boot(char *files);
+void	scan_sunx86_boot(char *files);
+int	make_sun_label(void);
+int	make_sunx86_label(void);
+static	void	dup_sun_label(int part);
+static	int	sunboot_write(FILE *outfile);
+static	int	sunlabel_size(int starting_extent);
+static	int	sunlabel_write(FILE * outfile);
+static	int	genboot_size(int starting_extent);
+static	int	genboot_write(FILE * outfile);
 
 /*
  * Set the virtual geometry in the disk label.
  * If we like to make the geometry variable, we may change
  * dkl_ncyl and dkl_pcyl later.
  */
-LOCAL void
+static void
 init_sparc_label()
 {
 	i_to_4_byte(cd_label.dkl_vtoc.v_version, V_VERSION);
@@ -91,7 +91,7 @@
 	cd_label.dkl_magic[1] =	DKL_MAGIC_1;
 }
 
-LOCAL void
+static void
 init_sunx86_label()
 {
 	li_to_4_byte(sx86_label.dkl_vtoc.v_sanity, VTOC_SANE);
@@ -120,17 +120,15 @@
 /*
  * For command line parser: set ASCII label.
  */
-EXPORT void
-sparc_boot_label(label)
-	char	*label;
+void
+sparc_boot_label(char *label)
 {
 	strncpy(cd_label.dkl_ascilabel, label, 127);
 	cd_label.dkl_ascilabel[127] = '\0';
 }
 
-EXPORT void
-sunx86_boot_label(label)
-	char	*label;
+void
+sunx86_boot_label(char *label)
 {
 	strncpy(sx86_label.dkl_vtoc.v_asciilabel, label, 127);
 	sx86_label.dkl_vtoc.v_asciilabel[127] = '\0';
@@ -139,9 +137,8 @@
 /*
  * Parse the command line argument for boot images.
  */
-EXPORT void
-scan_sparc_boot(files)
-	char	*files;
+void
+scan_sparc_boot(char *files)
 {
 	char		*p;
 	int		i = 1;
@@ -180,9 +177,8 @@
 	}
 }
 
-EXPORT void
-scan_sunx86_boot(files)
-	char	*files;
+void
+scan_sunx86_boot(char *files)
 {
 	char		*p;
 	int		i = 0;
@@ -232,7 +228,7 @@
 /*
  * Finish the Sun disk label and compute the size of the additional data.
  */
-EXPORT int
+int
 make_sun_label()
 {
 	int	last;
@@ -276,7 +272,7 @@
  * ISO	Part 1 tag 4 flag 10 start    0 size    3839
  * ALL	Part 2 tag 0 flag  0 start    0 size 1318400
  */
-EXPORT int
+int
 make_sunx86_label()
 {
 	int	last;
@@ -338,9 +334,8 @@
 /*
  * Duplicate a partition of the Sun disk label until all partitions are filled up.
  */
-LOCAL void
-dup_sun_label(part)
-	int	part;
+static void
+dup_sun_label(int part)
 {
 	int	cyl;
 	int	nblk;
@@ -364,9 +359,8 @@
 /*
  * Write out Sun boot partitions.
  */
-LOCAL int
-sunboot_write(outfile)
-	FILE	*outfile;
+static int
+sunboot_write(FILE *outfile)
 {
 	char	buffer[SECTOR_SIZE];
 	int	i;
@@ -431,9 +425,8 @@
  * Do size management for the Sun disk label that is located in the first
  * sector of a disk.
  */
-LOCAL int
-sunlabel_size(starting_extent)
-	int	starting_extent;
+static int
+sunlabel_size(int starting_extent)
 {
 	if (last_extent != session_start)
 		comerrno(EX_BAD, "Cannot create sparc boot on offset != 0.\n");
@@ -447,9 +440,8 @@
  * If the -generic-boot option has been specified too, overlay the
  * Sun disk label on the firs 512 bytes of the generic boot code.
  */
-LOCAL int
-sunlabel_write(outfile)
-	FILE	*outfile;
+static int
+sunlabel_write(FILE *outfile)
 {
 		char	buffer[SECTOR_SIZE];
 	register char	*p;
@@ -506,9 +498,8 @@
 /*
  * Do size management for the generic boot code on sectors 0..16.
  */
-LOCAL int
-genboot_size(starting_extent)
-	int	starting_extent;
+static int
+genboot_size(int starting_extent)
 {
 	if (last_extent > (session_start + 1))
 		comerrno(EX_BAD, "Cannot create generic boot on offset != 0.\n");
@@ -520,9 +511,8 @@
  * Write the generic boot code to sectors 0..16.
  * If there is a Sun disk label, start writing at sector 1.
  */
-LOCAL int
-genboot_write(outfile)
-	FILE	*outfile;
+static int
+genboot_write(FILE *outfile)
 {
 	char	buffer[SECTOR_SIZE];
 	int	i;

Modified: nonameyet/branches/cleanup/mkisofs/desktop.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/desktop.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/desktop.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -70,18 +70,16 @@
 /*
  * from "data.h" - libhfs routines
  */
-extern	void d_putw	__PR((unsigned char *, short));
-extern	void d_putl	__PR((unsigned char *, long));
+extern	void d_putw(unsigned char *, short);
+extern	void d_putl(unsigned char *, long);
 
-int	make_desktop	__PR((hfsvol *vol, int end));
+int	make_desktop(hfsvol *vol, int end);
 
 
 extern	hce_mem *hce;	/* libhfs/mkisofs extras */
 
 int
-make_desktop(vol, end)
-	hfsvol	*vol;
-	int	end;
+make_desktop(hfsvol *vol, int end)
 {
 	hfsfile		*hfp;			/* Mac file */
 	hfsdirent	ent;			/* Mac finderinfo */

Modified: nonameyet/branches/cleanup/mkisofs/diag/dump.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/diag/dump.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/diag/dump.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -65,33 +65,32 @@
 #define	ISO_BLOCKS(X)	(((X) / SECTOR_SIZE) + (((X)%SECTOR_SIZE)?1:0))
 
 #define	infile	in_image
-EXPORT	FILE		*infile = NULL;
-LOCAL	off_t		file_addr;
-LOCAL	off_t		sec_addr = (off_t)-1;
-LOCAL	Uchar		sector[2048];
+FILE		*infile = NULL;
+static	off_t		file_addr;
+static	off_t		sec_addr = (off_t)-1;
+static	Uchar		sector[2048];
 #define	PAGE	256
-LOCAL	Uchar		buffer[PAGE];
-LOCAL	Uchar		search[64];
+static	Uchar		buffer[PAGE];
+static	Uchar		search[64];
 
 #ifdef	USE_V7_TTY
-LOCAL	struct sgttyb	savetty;
-LOCAL	struct sgttyb	newtty;
+static	struct sgttyb	savetty;
+static	struct sgttyb	newtty;
 #else
-LOCAL	struct termios	savetty;
-LOCAL	struct termios	newtty;
+static	struct termios	savetty;
+static	struct termios	newtty;
 #endif
 
-LOCAL void	reset_tty	__PR((void));
-LOCAL void	set_tty		__PR((void));
-LOCAL void	onsusp		__PR((int sig));
-LOCAL void	crsr2		__PR((int row, int col));
-LOCAL void	readblock	__PR((void));
-LOCAL void	showblock	__PR((int flag));
-LOCAL int	getbyte		__PR((void));
-LOCAL void	usage		__PR((int excode));
-EXPORT int	main		__PR((int argc, char *argv[]));
+static void	reset_tty(void);
+static void	set_tty(void);
+static void	onsusp(int sig);
+static void	crsr2(int row, int col);
+static void	readblock(void);
+static void	showblock(int flag);
+static int	getbyte(void);
+static void	usage(int excode);
 
-LOCAL void
+static void
 reset_tty()
 {
 #ifdef USE_V7_TTY
@@ -112,7 +111,7 @@
 	}
 }
 
-LOCAL void
+static void
 set_tty()
 {
 #ifdef USE_V7_TTY
@@ -137,9 +136,8 @@
 /*
  * Come here when we get a suspend signal from the terminal
  */
-LOCAL void
-onsusp(sig)
-	int	sig;
+static void
+onsusp(int sig)
 {
 #ifdef	SIGTTOU
 	/* ignore SIGTTOU so we don't get stopped if csh grabs the tty */
@@ -162,15 +160,13 @@
 }
 
 
-LOCAL void
-crsr2(row, col)
-	int	row;
-	int	col;
+static void
+crsr2(int row, int col)
 {
 	printf("\033[%d;%dH", row, col);
 }
 
-LOCAL void
+static void
 readblock()
 {
 	off_t	dpos = file_addr - sec_addr;
@@ -189,9 +185,8 @@
 	movebytes(&sector[dpos], buffer, sizeof (buffer));
 }
 
-LOCAL void
-showblock(flag)
-	int	flag;
+static void
+showblock(int flag)
 {
 	unsigned int	k;
 	int		i;
@@ -231,7 +226,7 @@
 	fflush(stdout);
 }
 
-LOCAL int
+static int
 getbyte()
 {
 	char	c1;
@@ -243,9 +238,8 @@
 	return (c1);
 }
 
-LOCAL void
-usage(excode)
-	int	excode;
+static void
+usage(int excode)
 {
 	errmsgno(EX_BAD, "Usage: %s [options] [image]\n",
 						get_progname());
@@ -259,10 +253,8 @@
 	exit(excode);
 }
 
-EXPORT int
-main(argc, argv)
-	int	argc;
-	char	*argv[];
+int
+main(int argc, char *argv[])
 {
 	int	cac;
 	char	* const *cav;
@@ -375,7 +367,7 @@
 #ifdef	SIGTSTP
 	signal(SIGTSTP, onsusp);
 #endif
-	on_comerr((void(*)__PR((int, void *)))reset_tty, NULL);
+	on_comerr((void(*)(int, void *))reset_tty, NULL);
 
 	do {
 		if (file_addr < (off_t)0) file_addr = (off_t)0;

Modified: nonameyet/branches/cleanup/mkisofs/diag/isodebug.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/diag/isodebug.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/diag/isodebug.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -120,15 +120,13 @@
 #define	GET_BINT(a)	a_to_4_byte(&((unsigned char *) (a))[4])
 
 #define	infile	in_image
-EXPORT	FILE		*infile = NULL;
+FILE		*infile = NULL;
 
-LOCAL void	usage		__PR((int excode));
-LOCAL char	*isodinfo	__PR((FILE *f));
-EXPORT int	main		__PR((int argc, char *argv[]));
+static void	usage(int excode);
+static char	*isodinfo(FILE *f);
 
-LOCAL void
-usage(excode)
-	int	excode;
+static void
+usage(int excode)
 {
 	errmsgno(EX_BAD, "Usage: %s [options] image\n",
 						get_progname());
@@ -142,9 +140,8 @@
 	exit(excode);
 }
 
-LOCAL char *
-isodinfo(f)
-	FILE	*f;
+static char *
+isodinfo(FILE *f)
 {
 static	struct iso9660_voldesc		vd;
 	struct iso9660_pr_voldesc	*vp;
@@ -204,10 +201,8 @@
 	return ((char *)&vd);
 }
 
-EXPORT int
-main(argc, argv)
-	int	argc;
-	char	*argv[];
+int
+main(int argc, char *argv[])
 {
 	int	cac;
 	char	* const *cav;

Modified: nonameyet/branches/cleanup/mkisofs/diag/isodump.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/diag/isodump.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/diag/isodump.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -138,24 +138,22 @@
 	unsigned char name			[1];
 };
 
-LOCAL int	isonum_731	__PR((char * p));
-LOCAL int	isonum_721	__PR((char * p));
-LOCAL int	isonum_723	__PR((char * p));
-LOCAL int	isonum_733	__PR((unsigned char * p));
-LOCAL void	reset_tty	__PR((void));
-LOCAL void	set_tty		__PR((void));
-LOCAL void	onsusp		__PR((int signo));
-LOCAL void	crsr2		__PR((int row, int col));
-LOCAL int	parse_rr	__PR((unsigned char * pnt, int len, int cont_flag));
-LOCAL void	dump_rr		__PR((struct iso_directory_record * idr));
-LOCAL void	showblock	__PR((int flag));
-LOCAL int	getbyte		__PR((void));
-LOCAL void	usage		__PR((int excode));
-EXPORT int	main		__PR((int argc, char *argv[]));
+static int	isonum_731(char * p);
+static int	isonum_72(char * p);
+static int	isonum_723(char * p);
+static int	isonum_733(unsigned char * p);
+static void	reset_tty(void);
+static void	set_tty(void);
+static void	onsusp(int signo);
+static void	crsr2(int row, int col);
+static int	parse_rr(unsigned char * pnt, int len, int cont_flag);
+static void	dump_rr(struct iso_directory_record * idr);
+static void	showblock(int flag);
+static int	getbyte(void);
+static void	usage(int excode);
 
-LOCAL int
-isonum_731(p)
-	char	*p;
+static int
+isonum_731(char *p)
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8)
@@ -163,16 +161,14 @@
 		| ((p[3] & 0xff) << 24));
 }
 
-LOCAL int
-isonum_721(p)
-	char	*p;
+static int
+isonum_721(char *p)
 {
 	return ((p[0] & 0xff) | ((p[1] & 0xff) << 8));
 }
 
-LOCAL int
-isonum_723(p)
-	char	*p;
+static int
+isonum_723(char *p)
 {
 #if 0
 	if (p[0] != p[3] || p[1] != p[2]) {
@@ -188,22 +184,21 @@
 }
 
 
-LOCAL int
-isonum_733(p)
-	unsigned char *p;
+static int
+isonum_733(unsigned char *p)
 {
 	return (isonum_731((char *)p));
 }
 
 #ifdef	USE_V7_TTY
-LOCAL	struct sgttyb	savetty;
-LOCAL	struct sgttyb	newtty;
+static	struct sgttyb	savetty;
+static	struct sgttyb	newtty;
 #else
-LOCAL	struct termios savetty;
-LOCAL	struct termios newtty;
+static	struct termios savetty;
+static	struct termios newtty;
 #endif
 
-LOCAL void
+static void
 reset_tty()
 {
 #ifdef USE_V7_TTY
@@ -224,7 +219,7 @@
 	}
 }
 
-LOCAL void
+static void
 set_tty()
 {
 #ifdef USE_V7_TTY
@@ -247,9 +242,8 @@
 
 /* Come here when we get a suspend signal from the terminal */
 
-LOCAL void
-onsusp(signo)
-	int	signo;
+static void
+onsusp(int signo)
 {
 #ifdef	SIGTTOU
 	/* ignore SIGTTOU so we don't get stopped if csh grabs the tty */
@@ -273,19 +267,14 @@
 
 
 
-LOCAL void
-crsr2(row, col)
-	int	row;
-	int	col;
+static void
+crsr2(int row, int col)
 {
 	printf("\033[%d;%dH", row, col);
 }
 
-LOCAL int
-parse_rr(pnt, len, cont_flag)
-	unsigned char	*pnt;
-	int		len;
-	int		cont_flag;
+static int
+parse_rr(unsigned char *pnt, int len, int cont_flag)
 {
 	int		slen;
 	int		ncount;
@@ -432,9 +421,8 @@
 	return (flag2);
 }
 
-LOCAL void
-dump_rr(idr)
-	struct iso_directory_record *idr;
+static void
+dump_rr(struct iso_directory_record *idr)
 {
 	int		len;
 	unsigned char	*pnt;
@@ -453,9 +441,8 @@
 }
 
 
-LOCAL void
-showblock(flag)
-	int	flag;
+static void
+showblock(int flag)
 {
 	int	i;
 	int	j;
@@ -513,7 +500,7 @@
 	fflush(stdout);
 }
 
-LOCAL int
+static int
 getbyte()
 {
 	char	c1;
@@ -525,9 +512,8 @@
 	return (c1);
 }
 
-LOCAL void
-usage(excode)
-	int	excode;
+static void
+usage(int excode)
 {
 	errmsgno(EX_BAD, "Usage: %s [options] image\n",
 						get_progname());
@@ -541,10 +527,8 @@
 	exit(excode);
 }
 
-EXPORT int
-main(argc, argv)
-	int	argc;
-	char	*argv[];
+int
+main(int argc, char *argv[])
 {
 	int	cac;
 	char	* const *cav;
@@ -669,7 +653,7 @@
 #ifdef	SIGTSTP
 	signal(SIGTSTP, onsusp);
 #endif
-	on_comerr((void(*)__PR((int, void *)))reset_tty, NULL);
+	on_comerr((void(*)(int, void *))reset_tty, NULL);
 
 	do {
 		if (file_addr < 0)

Modified: nonameyet/branches/cleanup/mkisofs/diag/isoinfo.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/diag/isoinfo.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/diag/isoinfo.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -175,40 +175,37 @@
 #define	ISODCL(from, to) (to - from + 1)
 
 
-int	isonum_721	__PR((char * p));
-int	isonum_723	__PR((char * p));
-int	isonum_731	__PR((char * p));
-int	isonum_732	__PR((char * p));
-int	isonum_733	__PR((unsigned char * p));
-void	printchars	__PR((char *s, int n));
-char	*sdate		__PR((char *dp));
-void	dump_pathtab	__PR((int block, int size));
-int	parse_rr	__PR((unsigned char * pnt, int len, int cont_flag));
-void	find_rr		__PR((struct iso_directory_record * idr, Uchar **pntp, int *lenp));
-int	dump_rr		__PR((struct iso_directory_record * idr));
-void	dump_stat	__PR((struct iso_directory_record * idr, int extent));
-void	extract_file	__PR((struct iso_directory_record * idr));
-void	parse_dir	__PR((char * rootname, int extent, int len));
-void	usage		__PR((int excode));
-int	main		__PR((int argc, char *argv[]));
+int	isonum_721(char * p);
+int	isonum_723(char * p);
+int	isonum_731(char * p);
+int	isonum_732(char * p);
+int	isonum_733(unsigned char * p);
+void	printchars(char *s, int n);
+char	*sdate(char *dp);
+void	dump_pathtab(int block, int size);
+int	parse_rr(unsigned char * pnt, int len, int cont_flag);
+void	find_rr(struct iso_directory_record * idr, Uchar **pntp, int *lenp);
+int	dump_rr(struct iso_directory_record * idr);
+void	dump_stat(struct iso_directory_record * idr, int extent);
+void	extract_file(struct iso_directory_record * idr);
+void	parse_dir(char * rootname, int extent, int len);
+void	usage(int excode);
 
-LOCAL	void	printf_bootinfo	__PR((FILE *f, int bootcat_offset));
-LOCAL	char	*arch_name	__PR((int val));
-LOCAL	char	*boot_name	__PR((int val));
-LOCAL	char	*bootmedia_name	__PR((int val));
+static	void	printf_bootinfo(FILE *f, int bootcat_offset);
+static	char	*arch_name(int val);
+static	char	*boot_name(int val);
+static	char	*bootmedia_name(int val);
 
 
 int
-isonum_721(p)
-	char	*p;
+isonum_721(char *p)
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8));
 }
 
 int
-isonum_723(p)
-	char * p;
+isonum_723(char *p)
 {
 #if 0
 	if (p[0] != p[3] || p[1] != p[2]) {
@@ -224,8 +221,7 @@
 }
 
 int
-isonum_731(p)
-	char	*p;
+isonum_731(char *p)
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8)
@@ -234,8 +230,7 @@
 }
 
 int
-isonum_732(p)
-	char	*p;
+isonum_732(char *p)
 {
 	return ((p[3] & 0xff)
 		| ((p[2] & 0xff) << 8)
@@ -244,16 +239,13 @@
 }
 
 int
-isonum_733(p)
-	unsigned char	*p;
+isonum_733(unsigned char *p)
 {
 	return (isonum_731((char *)p));
 }
 
 void
-printchars(s, n)
-	char	*s;
-	int	n;
+printchars(char *s, int n)
 {
 	int	i;
 	char	*p;
@@ -275,8 +267,7 @@
  * Print date info from PVD
  */
 char *
-sdate(dp)
-	char	*dp;
+sdate(char *dp)
 {
 	static	char	d[30];
 
@@ -297,9 +288,7 @@
 }
 
 void
-dump_pathtab(block, size)
-	int	block;
-	int	size;
+dump_pathtab(int block, int size)
 {
 	unsigned char	*buf;
 	int		offset;
@@ -367,10 +356,7 @@
 }
 
 int
-parse_rr(pnt, len, cont_flag)
-	unsigned char	*pnt;
-	int		len;
-	int		cont_flag;
+parse_rr(unsigned char *pnt, int len, int cont_flag)
 {
 	int slen;
 	int xlen;
@@ -512,10 +498,7 @@
 }
 
 void
-find_rr(idr, pntp, lenp)
-	struct iso_directory_record *idr;
-	Uchar	**pntp;
-	int	*lenp;
+find_rr(struct iso_directory_record *idr, Uchar **pntp, int *lenp)
 {
 	struct iso_xa_dir_record *xadp;
 	int len;
@@ -546,8 +529,7 @@
 }
 
 int
-dump_rr(idr)
-	struct iso_directory_record *idr;
+dump_rr(struct iso_directory_record *idr)
 {
 	int len;
 	unsigned char * pnt;
@@ -570,9 +552,7 @@
 				"Aug", "Sep", "Oct", "Nov", "Dec"};
 
 void
-dump_stat(idr, extent)
-	struct iso_directory_record *idr;
-	int	extent;
+dump_stat(struct iso_directory_record *idr, int extent)
 {
 	int	i;
 	char	outline[80];
@@ -652,8 +632,7 @@
 }
 
 void
-extract_file(idr)
-	struct iso_directory_record *idr;
+extract_file(struct iso_directory_record *idr)
 {
 	int		extent, len, tlen;
 	unsigned char	buff[2048];
@@ -681,10 +660,7 @@
 }
 
 void
-parse_dir(rootname, extent, len)
-	char	*rootname;
-	int	extent;
-	int	len;
+parse_dir(char *rootname, int extent, int len)
 {
 	char		testname[PATH_MAX+1];
 	struct todo 	*td;
@@ -813,8 +789,7 @@
 }
 
 void
-usage(excode)
-	int	excode;
+usage(int excode)
 {
 	errmsgno(EX_BAD, "Usage: %s [options] -i filename\n", get_progname());
 
@@ -839,9 +814,7 @@
 }
 
 int
-main(argc, argv)
-	int	argc;
-	char	*argv[];
+main(int argc, char *argv[])
 {
 	int	cac;
 	char	* const *cav;
@@ -1269,10 +1242,8 @@
 
 #include <intcvt.h>
 
-LOCAL void
-printf_bootinfo(f, bootcat_offset)
-	FILE	*f;
-	int	bootcat_offset;
+static void
+printf_bootinfo(FILE *f, int bootcat_offset)
 {
 	struct eltorito_validation_entry	*evp;
 	struct eltorito_defaultboot_entry	*ebe;
@@ -1303,9 +1274,8 @@
 
 }
 
-LOCAL char *
-arch_name(val)
-	int	val;
+static char *
+arch_name(int val)
 {
 	switch (val) {
 
@@ -1320,9 +1290,8 @@
 	}
 }
 
-LOCAL char *
-boot_name(val)
-	int	val;
+static char *
+boot_name(int val)
 {
 	switch (val) {
 
@@ -1335,9 +1304,8 @@
 	}
 }
 
-LOCAL char *
-bootmedia_name(val)
-	int	val;
+static char *
+bootmedia_name(int val)
 {
 	switch (val) {
 

Modified: nonameyet/branches/cleanup/mkisofs/diag/isovfy.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/diag/isovfy.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/diag/isovfy.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -134,30 +134,28 @@
 	unsigned char name			[38];
 };
 
-LOCAL int	isonum_721	__PR((char * p));
-LOCAL int	isonum_723	__PR((char * p));
-LOCAL int	isonum_711	__PR((char * p));
-LOCAL int	isonum_731	__PR((char * p));
-LOCAL int	isonum_722	__PR((char * p));
-LOCAL int	isonum_732	__PR((char * p));
-LOCAL int	isonum_733	__PR((unsigned char * p));
-LOCAL int	parse_rr	__PR((unsigned char * pnt, int len, int cont_flag));
-LOCAL int	dump_rr		__PR((struct iso_directory_record * idr));
-LOCAL void	check_tree	__PR((off_t file_addr, int file_size, off_t parent_addr));
-LOCAL void	check_path_tables __PR((int typel_extent, int typem_extent, int path_table_size));
-LOCAL void	usage		__PR((int excode));
-EXPORT int	main		__PR((int argc, char *argv[]));
+static int	isonum_721(char * p);
+static int	isonum_723(char * p);
+static int	isonum_711(char * p);
+static int	isonum_731(char * p);
+static int	isonum_722(char * p);
+static int	isonum_732(char * p);
+static int	isonum_733(unsigned char * p);
+static int	parse_rr(unsigned char * pnt, int len, int cont_flag);
+static int	dump_rr(struct iso_directory_record * idr);
+static void	check_tree(off_t file_addr, int file_size, off_t parent_addr);
+static void	check_path_tables(int typel_extent, int typem_extent, 
+										int path_table_size);
+static void	usage(int excode);
 
-LOCAL int
-isonum_721(p)
-	char	*p;
+static int
+isonum_721(char *p)
 {
 	return ((p[0] & 0xff) | ((p[1] & 0xff) << 8));
 }
 
-LOCAL int
-isonum_723(p)
-	char	*p;
+static int
+isonum_723(char *p)
 {
 #if 0
 	if (p[0] != p[3] || p[1] != p[2]) {
@@ -172,16 +170,14 @@
 	return (isonum_721(p));
 }
 
-LOCAL int
-isonum_711(p)
-	char	*p;
+static int
+isonum_711(char *p)
 {
 	return (*p & 0xff);
 }
 
-LOCAL int
-isonum_731(p)
-	char	*p;
+static int
+isonum_731(char *p)
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8)
@@ -189,17 +185,15 @@
 		| ((p[3] & 0xff) << 24));
 }
 
-LOCAL int
-isonum_722(p)
-	char	*p;
+static int
+isonum_722(char *p)
 {
 	return ((p[1] & 0xff)
 		| ((p[0] & 0xff) << 8));
 }
 
-LOCAL int
-isonum_732(p)
-	char	*p;
+static int
+isonum_732(char *p)
 {
 	return ((p[3] & 0xff)
 		| ((p[2] & 0xff) << 8)
@@ -207,9 +201,8 @@
 		| ((p[0] & 0xff) << 24));
 }
 
-LOCAL int
-isonum_733(p)
-	unsigned char	*p;
+static int
+isonum_733(unsigned char *p)
 {
 	return (isonum_731((char *)p));
 }
@@ -219,11 +212,8 @@
 int	rr_goof;
 
 
-LOCAL int
-parse_rr(pnt, len, cont_flag)
-	unsigned char	*pnt;
-	int		len;
-	int		cont_flag;
+static int
+parse_rr(unsigned char *pnt, int len, int cont_flag)
 {
 	int		slen;
 	int		ncount;
@@ -370,9 +360,8 @@
 	return (flag2);
 }
 
-LOCAL int
-dump_rr(idr)
-	struct iso_directory_record *idr;
+static int
+dump_rr(struct iso_directory_record *idr)
 {
 	int len;
 	char * pnt;
@@ -395,15 +384,12 @@
 }
 
 
-LOCAL int	dir_count = 0;
-LOCAL int	dir_size_count = 0;
-LOCAL int	ngoof = 0;
+static int	dir_count = 0;
+static int	dir_size_count = 0;
+static int	ngoof = 0;
 
-LOCAL void
-check_tree(file_addr, file_size, parent_addr)
-	off_t	file_addr;
-	int	file_size;
-	off_t	parent_addr;
+static void
+check_tree(off_t file_addr, int file_size, off_t parent_addr)
 {
 	unsigned char	buffer[2048];
 	unsigned int	k;
@@ -593,11 +579,8 @@
 	unsigned short	parent;
 };
 
-LOCAL void
-check_path_tables(typel_extent, typem_extent, path_table_size)
-	int	typel_extent;
-	int	typem_extent;
-	int	path_table_size;
+static void
+check_path_tables(int typel_extent, int typem_extent, int path_table_size)
 {
 	int	count;
 	int	j;
@@ -672,9 +655,8 @@
 	}
 }
 
-LOCAL void
-usage(excode)
-	int	excode;
+static void
+usage(int excode)
 {
 	errmsgno(EX_BAD, "Usage: %s [options] image\n",
 						get_progname());
@@ -688,10 +670,8 @@
 	exit(excode);
 }
 
-EXPORT int
-main(argc, argv)
-	int	argc;
-	char	*argv[];
+int
+main(int argc, char *argv[])
 {
 	int	cac;
 	char	* const *cav;

Modified: nonameyet/branches/cleanup/mkisofs/dvd_file.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/dvd_file.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/dvd_file.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -45,22 +45,19 @@
 #include "dvd_file.h"
 #include "ifo_read.h"
 
-LOCAL	void	bsort		__PR((int sector[], int title[], int size));
-LOCAL	void	uniq		__PR((int sector[], int title[],
-					int title_sets_array[],
-					int sector_sets_array[], int titles));
-LOCAL	void	DVDFreeFileSetArrays __PR((int * sector, int * title, int * title_sets_array,
-					int * sector_sets_array));
-EXPORT	void	DVDFreeFileSet	__PR((title_set_info_t * title_set_info));
-EXPORT	title_set_info_t * DVDGetFileSet __PR((char * dvd));
-EXPORT	int	DVDGetFilePad	__PR((title_set_info_t * title_set_info, char * name));
+static	void	bsort(int sector[], int title[], int size);
+static	void	uniq(int sector[], int title[], int title_sets_array[],
+						  int sector_sets_array[], int titles);
+static	void	DVDFreeFileSetArrays(int *sector, int *title, 
+												int *title_sets_array, 
+												int *sector_sets_array);
+void	DVDFreeFileSet(title_set_info_t *title_set_info);
+title_set_info_t *DVDGetFileSet(char *dvd);
+int	DVDGetFilePad(title_set_info_t *title_set_info, char *name);
 
 
-LOCAL void
-bsort(sector, title, size)
-	int	sector[];
-	int	title[];
-	int	size;
+static void
+bsort(int sector[], int title[], int size)
 {
 	int	temp_title;
 	int	temp_sector;
@@ -82,13 +79,9 @@
 }
 
 
-LOCAL void
-uniq(sector, title, title_sets_array, sector_sets_array, titles)
-	int	sector[];
-	int	title[];
-	int	title_sets_array[];
-	int	sector_sets_array[];
-	int	titles;
+static void
+uniq(int sector[], int title[], int title_sets_array[], 
+	  int sector_sets_array[], int titles)
 {
 	int	i;
 	int	j;
@@ -115,12 +108,9 @@
 
 }
 
-LOCAL void
-DVDFreeFileSetArrays(sector, title, title_sets_array, sector_sets_array)
-	int	* sector;
-	int	* title;
-	int	* title_sets_array;
-	int	* sector_sets_array;
+static void
+DVDFreeFileSetArrays(int *sector, int *title, int *title_sets_array, 
+							int *sector_sets_array)
 {
 	free(sector);
 	free(title);
@@ -128,17 +118,15 @@
 	free(sector_sets_array);
 }
 
-EXPORT void
-DVDFreeFileSet(title_set_info)
-	title_set_info_t * title_set_info;
+void
+DVDFreeFileSet(title_set_info_t *title_set_info)
 {
 	free(title_set_info->title_set);
 	free(title_set_info);
 }
 
-EXPORT title_set_info_t *
-DVDGetFileSet(dvd)
-	char * dvd;
+title_set_info_t *
+DVDGetFileSet(char *dvd)
 {
 	/*
 	 * TODO  Fix close of files if
@@ -730,10 +718,8 @@
 
 }
 
-EXPORT int
-DVDGetFilePad(title_set_info, name)
-	title_set_info_t * title_set_info;
-	char *  name;
+int
+DVDGetFilePad(title_set_info_t *title_set_info, char *name)
 {
 	char	title_a[3];
 	char	vob_a[2];

Modified: nonameyet/branches/cleanup/mkisofs/dvd_file.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/dvd_file.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/dvd_file.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -34,8 +34,8 @@
 #ifndef	_DVD_FILE_H
 #define	_DVD_FILE_H
 
-extern	void		DVDFreeFileSet		__PR((title_set_info_t * title_set_info));
-extern	title_set_info_t *DVDGetFileSet		__PR((char * dvd));
-extern	int		DVDGetFilePad		__PR((title_set_info_t * title_set_info, char * name));
+extern	void		DVDFreeFileSet(title_set_info_t *title_set_info);
+extern	title_set_info_t *DVDGetFileSet(char *dvd);
+extern	int		DVDGetFilePad(title_set_info_t *title_set_info, char *name);
 
 #endif	/* _DVD_FILE_H */

Modified: nonameyet/branches/cleanup/mkisofs/dvd_reader.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/dvd_reader.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/dvd_reader.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -64,23 +64,22 @@
 };
 
 
-EXPORT	void		DVDCloseFile	__PR((dvd_file_t *dvd_file));
-LOCAL	dvd_file_t *	DVDOpenFilePath	__PR((dvd_reader_t *dvd, char *filename));
-LOCAL	dvd_file_t *	DVDOpenVOBPath	__PR((dvd_reader_t *dvd, int title, int menu));
-EXPORT	dvd_file_t *	DVDOpenFile	__PR((dvd_reader_t *dvd, int titlenum,
-						dvd_read_domain_t domain));
-LOCAL	dvd_reader_t *	DVDOpenPath	__PR((const char *path_root));
-EXPORT	dvd_reader_t *	DVDOpen		__PR((const char *path));
-EXPORT	void		DVDClose	__PR((dvd_reader_t *dvd));
-EXPORT	ssize_t		DVDFileSize	__PR((dvd_file_t *dvd_file));
+void		DVDCloseFile(dvd_file_t *dvd_file);
+static	dvd_file_t *DVDOpenFilePath(dvd_reader_t *dvd, char *filename);
+static	dvd_file_t *DVDOpenVOBPath(dvd_reader_t *dvd, int title, int menu);
+dvd_file_t *DVDOpenFile(dvd_reader_t *dvd, int titlenum, 
+								dvd_read_domain_t domain);
+static	dvd_reader_t *DVDOpenPath(const char *path_root);
+dvd_reader_t *DVDOpen(const char *path);
+void		DVDClose(dvd_reader_t *dvd);
+ssize_t		DVDFileSize(dvd_file_t *dvd_file);
 
 
 /*
  * Free a DVD file
  */
-EXPORT void
-DVDCloseFile(dvd_file)
-	dvd_file_t	*dvd_file;
+void
+DVDCloseFile(dvd_file_t *dvd_file)
 {
 	free(dvd_file);
 	dvd_file = 0;
@@ -90,10 +89,8 @@
 /*
  * Stat a IFO or BUP file from a DVD directory tree.
  */
-LOCAL dvd_file_t *
-DVDOpenFilePath(dvd, filename)
-	dvd_reader_t	*dvd;
-	char		*filename;
+static dvd_file_t *
+DVDOpenFilePath(dvd_reader_t *dvd, char *filename)
 {
 
 	char		full_path[PATH_MAX + 1];
@@ -125,11 +122,8 @@
 /*
  * Stat a VOB file from a DVD directory tree.
  */
-LOCAL dvd_file_t *
-DVDOpenVOBPath(dvd, title, menu)
-	dvd_reader_t	*dvd;
-	int		title;
-	int		menu;
+static dvd_file_t *
+DVDOpenVOBPath(dvd_reader_t *dvd, int title, int menu)
 {
 
 	char		filename[PATH_MAX + 1];
@@ -176,14 +170,7 @@
  * Stat a DVD file from a DVD directory tree
  */
 EXPORT dvd_file_t *
-#ifdef	PROTOTYPES
 DVDOpenFile(dvd_reader_t *dvd, int titlenum, dvd_read_domain_t domain)
-#else
-DVDOpenFile(dvd, titlenum, domain)
-	dvd_reader_t	*dvd;
-	int		titlenum;
-	dvd_read_domain_t domain;
-#endif
 {
 	char		filename[MAX_UDF_FILE_NAME_LEN];
 
@@ -233,9 +220,8 @@
 /*
  * Stat a DVD directory structure
  */
-LOCAL dvd_reader_t *
-DVDOpenPath(path_root)
-	const char	*path_root;
+static dvd_reader_t *
+DVDOpenPath(const char *path_root)
 {
 	dvd_reader_t	*dvd;
 
@@ -251,9 +237,8 @@
 /*
  * Stat a DVD structure - this one only works with directory structures
  */
-EXPORT dvd_reader_t *
-DVDOpen(path)
-	const char	*path;
+dvd_reader_t *
+DVDOpen(const char *path)
 {
 	struct stat	fileinfo;
 	int		ret;
@@ -290,9 +275,8 @@
 /*
  * Free a DVD structure - this one will only close a directory tree
  */
-EXPORT void
-DVDClose(dvd)
-	dvd_reader_t	*dvd;
+void
+DVDClose(dvd_reader_t *dvd)
 {
 	if (dvd) {
 		if (dvd->path_root) free(dvd->path_root);
@@ -306,9 +290,8 @@
 /*
  * Return the size of a DVD file
  */
-EXPORT ssize_t
-DVDFileSize(dvd_file)
-	dvd_file_t	*dvd_file;
+ssize_t
+DVDFileSize(dvd_file_t *dvd_file)
 {
 	return (dvd_file->filesize);
 }

Modified: nonameyet/branches/cleanup/mkisofs/dvd_reader.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/dvd_reader.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/dvd_reader.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -85,7 +85,7 @@
  */
 
 
-extern	dvd_reader_t *DVDOpen	__PR((const char *));
+extern	dvd_reader_t *DVDOpen(const char *);
 
 
 /*
@@ -96,7 +96,7 @@
  */
 
 
-extern	void DVDClose		__PR((dvd_reader_t *));
+extern	void DVDClose(dvd_reader_t *);
 
 /*
  * INFO_FILE       : VIDEO_TS.IFO     (manager)
@@ -127,14 +127,14 @@
  * (VIDEO_TS.[IFO,BUP,VOB]).  Returns a file structure which may be used for
  * reads, or 0 if the file was not found.
  */
-extern	dvd_file_t * DVDOpenFile	__PR((dvd_reader_t *, int, dvd_read_domain_t));
+extern	dvd_file_t * DVDOpenFile(dvd_reader_t *, int, dvd_read_domain_t);
 
 /*
  * DVDCloseFile(dvd_file);
  *
  * Closes a file and frees the associated structure.
  */
-extern	void DVDCloseFile		__PR((dvd_file_t *));
+extern	void DVDCloseFile(dvd_file_t *);
 
 
 /*
@@ -142,7 +142,7 @@
  *
  * Returns the file size in blocks.
  */
-extern	ssize_t DVDFileSize		__PR((dvd_file_t *));
+extern	ssize_t DVDFileSize(dvd_file_t *);
 
 
 #ifdef __cplusplus

Modified: nonameyet/branches/cleanup/mkisofs/eltorito.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/eltorito.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/eltorito.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -58,23 +58,22 @@
 static struct disk_master_boot_record disk_mbr;
 static unsigned int bcat_de_flags;
 
-	void	init_boot_catalog	__PR((const char *path));
-	void	insert_boot_cat		__PR((void));
-static	void	get_torito_desc		__PR((struct eltorito_boot_descriptor *boot_desc));
-static	void	fill_boot_desc		__PR((struct eltorito_defaultboot_entry *boot_desc_entry,
-						struct eltorito_boot_entry_info *boot_entry));
-	void	get_boot_entry		__PR((void));
-	void	new_boot_entry		__PR((void));
-static	int	tvd_write		__PR((FILE * outfile));
+void	init_boot_catalog(const char *path);
+void	insert_boot_cat(void);
+static	void	get_torito_desc(struct eltorito_boot_descriptor *boot_desc);
+static	void	fill_boot_desc(struct eltorito_defaultboot_entry *boot_desc_entry,
+										struct eltorito_boot_entry_info *boot_entry);
+void	get_boot_entry(void);
+void	new_boot_entry(void);
+static	int	tvd_write(FILE *outfile);
 
 
-LOCAL	char	*bootcat_path;		/* filename of boot catalog */
+static	char	*bootcat_path;		/* filename of boot catalog */
 /*
  * Make sure any existing boot catalog is excluded
  */
 void
-init_boot_catalog(path)
-	const char	*path;
+init_boot_catalog(const char *path)
 {
 #ifdef	SORTING
 	struct eltorito_boot_entry_info * cbe;
@@ -272,8 +271,7 @@
 }
 
 static void
-get_torito_desc(boot_desc)
-	struct eltorito_boot_descriptor	*boot_desc;
+get_torito_desc(struct eltorito_boot_descriptor *boot_desc)
 {
 	int			checksum;
 	unsigned char		*checksum_ptr;
@@ -367,9 +365,8 @@
 }/* get_torito_desc(... */
 
 static void
-fill_boot_desc(boot_desc_entry, boot_entry)
-	struct eltorito_defaultboot_entry *boot_desc_entry;
-	struct eltorito_boot_entry_info *boot_entry;
+fill_boot_desc(struct eltorito_defaultboot_entry *boot_desc_entry, 
+					struct eltorito_boot_entry_info *boot_entry)
 {
 	struct directory_entry	*de;	/* Boot file */
 	int			bootmbr;
@@ -694,8 +691,7 @@
  * Function to write the EVD for the disc.
  */
 static int
-tvd_write(outfile)
-	FILE	*outfile;
+tvd_write(FILE *outfile)
 {
 	/* check the boot image is not NULL */
 	if (!boot_image) {

Modified: nonameyet/branches/cleanup/mkisofs/endian.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/endian.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/endian.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -14,9 +14,7 @@
 #include "endianconv.h"
 
 /* Write a 64-bit quantity out into memory in BIG ENDIAN order */
-void write_be64(in, out)
-    unsigned long long in;
-    unsigned char *out;
+void write_be64(unsigned long long in, unsigned char *out)
 {
     out[0] = (in >> 56) & 0xFF;
     out[1] = (in >> 48) & 0xFF;
@@ -29,8 +27,7 @@
 }
 
 /* Read in a 64-bit BIG ENDIAN quantity */
-unsigned long long read_be64(in)
-    unsigned char *in;
+unsigned long long read_be64(unsigned char *in)
 {
     unsigned long long result = 0;
 
@@ -47,9 +44,7 @@
 }
 
 /* Write a 64-bit quantity out into memory in LITTLE ENDIAN order */
-void write_le64(in, out)
-    unsigned long long in;
-    unsigned char *out;
+void write_le64(unsigned long long in, unsigned char *out)
 {
     out[0] = in & 0xFF;
     out[1] = (in >> 8) & 0xFF;
@@ -62,8 +57,7 @@
 }
 
 /* Read in a 64-bit LITTLE ENDIAN quantity */
-unsigned long long read_le64(in)
-    unsigned char *in;
+unsigned long long read_le64(unsigned char *in)
 {
     unsigned long long result = 0;
 
@@ -80,9 +74,7 @@
 }
 
 /* Write a 48-bit quantity out into memory in LITTLE ENDIAN order */
-void write_le48(in, out)
-    unsigned long long in;
-    unsigned char *out;
+void write_le48(unsigned long long in, unsigned char *out)
 {
     out[0] = in & 0xFF;
     out[1] = (in >> 8) & 0xFF;
@@ -93,8 +85,7 @@
 }
 
 /* Read in a 48-bit LITTLE ENDIAN quantity */
-unsigned long long read_le48(in)
-    unsigned char *in;
+unsigned long long read_le48(unsigned char *in)
 {
     unsigned long long result = 0;
 
@@ -109,9 +100,7 @@
 }
 
 /* Write a 32-bit quantity out into memory in BIG ENDIAN order */
-void write_be32(in, out)
-    unsigned long in;
-    unsigned char *out;
+void write_be32(unsigned long in, unsigned char *out)
 {
     out[0] = (in >> 24) & 0xFF;
     out[1] = (in >> 16) & 0xFF;
@@ -120,8 +109,7 @@
 }
 
 /* Read in a 32-bit BIG ENDIAN quantity */
-unsigned long read_be32(in)
-    unsigned char *in;
+unsigned long read_be32(unsigned char *in)
 {
     unsigned long result = 0;
 
@@ -134,9 +122,7 @@
 }
 
 /* Write a 32-bit quantity out into memory in LITTLE ENDIAN order */
-void write_le32(in, out)
-    unsigned long in;
-    unsigned char *out;
+void write_le32(unsigned long in, unsigned char *out)
 {
     out[0] = in & 0xFF;
     out[1] = (in >> 8) & 0xFF;
@@ -145,8 +131,7 @@
 }
 
 /* Read in a 32-bit LITTLE ENDIAN quantity */
-unsigned long read_le32(in)
-    unsigned char *in;
+unsigned long read_le32(unsigned char *in)
 {
     unsigned long result = 0;
 
@@ -159,17 +144,14 @@
 }
 
 /* Write a 16-bit quantity out into memory in BIG ENDIAN order */
-void write_be16(in, out)
-    unsigned short in;
-    unsigned char *out;
+void write_be16(unsigned short in, unsigned char *out)
 {
     out[0] = (in >> 8) & 0xFF;
     out[1] = in & 0xFF;
 }
     
 /* Read in a 16-bit BIG ENDIAN quantity */
-unsigned short read_be16(in)
-    unsigned char *in;
+unsigned short read_be16(unsigned char *in)
 {
     unsigned short result = 0;
     
@@ -179,17 +161,14 @@
 }
 
 /* Write a 16-bit quantity out into memory in LITTLE ENDIAN order */
-void write_le16(in, out)
-    unsigned short in;
-    unsigned char *out;
+void write_le16(unsigned short in, unsigned char *out)
 {
     out[0] = in & 0xFF;
     out[1] = in & 0xFF >> 8;
 }
     
 /* Read in a 16-bit LITTLE ENDIAN quantity */
-unsigned short read_le16(in)
-    unsigned char *in;
+unsigned short read_le16(unsigned char *in)
 {
     unsigned short result = 0;
     

Modified: nonameyet/branches/cleanup/mkisofs/endianconv.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/endianconv.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/endianconv.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -10,20 +10,20 @@
  *
  */
 
-void                  write_be64  __PR((unsigned long long in, unsigned char *out));
-unsigned long long    read_be64   __PR((unsigned char *in));
-void                  write_le64  __PR((unsigned long long in, unsigned char *out));
-unsigned long long    read_le64   __PR((unsigned char *in));
+void                  write_be64(unsigned long long in, unsigned char *out);
+unsigned long long    read_be64(unsigned char *in);
+void                  write_le64(unsigned long long in, unsigned char *out);
+unsigned long long    read_le64(unsigned char *in);
 
-void                  write_le48  __PR((unsigned long long in, unsigned char *out));
-unsigned long long    read_le48   __PR((unsigned char *in));
+void                  write_le48(unsigned long long in, unsigned char *out);
+unsigned long long    read_le48(unsigned char *in);
 
-void                  write_be32  __PR((unsigned long in, unsigned char *out));
-unsigned long         read_be32   __PR((unsigned char *in));
-void                  write_le32  __PR((unsigned long in, unsigned char *out));
-unsigned long         read_le32   __PR((unsigned char *in));
+void                  write_be32(unsigned long in, unsigned char *out);
+unsigned long         read_be32(unsigned char *in);
+void                  write_le32(unsigned long in, unsigned char *out);
+unsigned long         read_le32(unsigned char *in);
 
-void                  write_be16  __PR((unsigned short in, unsigned char *out));
-unsigned short        read_be16   __PR((unsigned char *in));
-void                  write_le16  __PR((unsigned short in, unsigned char *out));
-unsigned short        read_le16   __PR((unsigned char *in));
+void                  write_be16(unsigned short in, unsigned char *out);
+unsigned short        read_be16(unsigned char *in);
+void                  write_le16(unsigned short in, unsigned char *out);
+unsigned short        read_le16(unsigned char *in);

Modified: nonameyet/branches/cleanup/mkisofs/exclude.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/exclude.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/exclude.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -34,13 +34,12 @@
 
 static char		*excl[MAXEXCL];
 
-void	exclude		__PR((char *fn));
-int	is_excluded	__PR((char *fn));
+void	exclude(char *fn);
+int	is_excluded(char *fn);
 
 
 void
-exclude(fn)
-	char		*fn;
+exclude(char *fn)
 {
 	register int	i;
 
@@ -67,8 +66,7 @@
 }
 
 int
-is_excluded(fn)
-	char		*fn;
+is_excluded(char *fn)
 {
 	register int	i;
 

Modified: nonameyet/branches/cleanup/mkisofs/exclude.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/exclude.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/exclude.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -17,5 +17,5 @@
  * CD image.
  */
 
-void exclude	__PR((char * fn));
-int is_excluded	__PR((char * fn));
+void exclude(char * fn);
+int is_excluded(char * fn);

Modified: nonameyet/branches/cleanup/mkisofs/files.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/files.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/files.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -48,13 +48,12 @@
 
 #ifdef ADD_FILES
 
-void	add_one_file	__PR((char *addpath, char *path));
-void	add_file_list	__PR((int argc, char **argv, int ind));
-void	add_file	__PR((char *filename));
-char *	look_up_addition __PR((char **newpath, char *path,
-					struct dirent **de));
-void	nuke_duplicates	__PR((char *path, struct dirent **de));
-struct dirent  *readdir_add_files __PR((char **pathp, char *path, DIR *dir));
+void	add_one_file(char *addpath, char *path);
+void	add_file_list(int argc, char **argv, int ind);
+void	add_file(char *filename);
+char *look_up_addition(char **newpath, char *path, struct dirent **de);
+void	nuke_duplicates(char *path, struct dirent **de);
+struct dirent  *readdir_add_files(char **pathp, char *path, DIR *dir);
 
 struct file_adds {
 	char			*name;
@@ -100,9 +99,7 @@
 struct file_adds *root_file_adds = NULL;
 
 void
-add_one_file(addpath, path)
-	char	*addpath;
-	char	*path;
+add_one_file(char *addpath, char *path)
 {
 	char			*cp;
 	char			*name;
@@ -193,10 +190,7 @@
  * Arguments:
  */
 void
-add_file_list(argc, argv, ind)
-	int	argc;
-	char	**argv;
-	int	ind;
+add_file_list(int argc, char **argv, int ind)
 {
 	char	*ptr;
 	char	*dup_arg;
@@ -217,8 +211,7 @@
 }
 
 void
-add_file(filename)
-	char	*filename;
+add_file(char *filename)
 {
 	char	buff[PATH_MAX];
 	FILE	*f;
@@ -272,10 +265,7 @@
 
 /* This function looks up additions. */
 char *
-look_up_addition(newpath, path, de)
-	char		**newpath;
-	char		*path;
-	struct dirent	**de;
+look_up_addition(char **newpath, char *path, struct dirent **de)
 {
 	char			*dup_path;
 	char			*cp;
@@ -323,9 +313,7 @@
 
 /* This function looks up additions. */
 void
-nuke_duplicates(path, de)
-	char		*path;
-	struct dirent	**de;
+nuke_duplicates(char *path, struct dirent **de)
 {
 	char			*dup_path;
 	char			*cp;
@@ -374,10 +362,7 @@
  */
 
 struct dirent  *
-readdir_add_files(pathp, path, dir)
-	char	**pathp;
-	char	*path;
-	DIR	*dir;
+readdir_add_files(char **pathp, char **path, DIR *dir)
 {
 	struct dirent  *de;
 
@@ -410,10 +395,7 @@
 
 #else
 struct dirent  *
-readdir_add_files(pathp, path, dir)
-	char	**pathp;
-	char	*path;
-	DIR	*dir;
+readdir_add_files(char **pathp, char *path, DIR *dir)
 {
 	return (readdir(dir));
 }

Modified: nonameyet/branches/cleanup/mkisofs/fnmatch.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/fnmatch.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/fnmatch.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -88,10 +88,7 @@
 /* Match STRING against the filename pattern PATTERN, returning zero if
    it matches, nonzero if not.  */
 int
-fnmatch (pattern, string, flags)
-     const char *pattern;
-     const char *string;
-     int flags;
+fnmatch (const char *pattern, const char *string, int flags)
 {
   register const char *p = pattern, *n = string;
   register char c;

Modified: nonameyet/branches/cleanup/mkisofs/fnmatch.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/fnmatch.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/fnmatch.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -92,8 +92,7 @@
  * Match STRING against the filename pattern PATTERN,
  * returning zero if it matches, FNM_NOMATCH if not.
  */
-extern int fnmatch __P((const char *__pattern, const char *__string,
-			int __flags));
+extern int fnmatch(const char *__pattern, const char *__string, int __flags);
 
 #ifdef	__cplusplus
 }

Modified: nonameyet/branches/cleanup/mkisofs/getopt.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/getopt.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/getopt.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -118,8 +118,8 @@
 
 #include "getopt.h"
 
-static	void		exchange	__PR((char **argv));
-static	const char *	_getopt_initialize __PR((const char *optstring));
+static	void		exchange(char **argv);
+static	const char *_getopt_initialize(const char *optstring);
 
 /* For communication from `getopt' to the caller.
    When `getopt' finds an option that takes an argument,
@@ -212,12 +212,10 @@
 
 char *getenv ();
 
-static char * my_index __PR((const char *str, int chr));
+static char *my_index(const char *str, int chr);
 
 static char *
-my_index (str, chr)
-     const char *str;
-     int chr;
+my_index (const char *str, int chr)
 {
   while (*str)
     {
@@ -278,8 +276,7 @@
    the new indices of the non-options in ARGV after they are moved.  */
 
 static void
-exchange (argv)
-     char **argv;
+exchange (char **argv)
 {
   int bottom = first_nonopt;
   int middle = last_nonopt;
@@ -336,8 +333,7 @@
 /* Initialize the internal data when the first call is made.  */
 
 static const char *
-_getopt_initialize (optstring)
-     const char *optstring;
+_getopt_initialize (const char *optstring)
 {
   /* Start processing options with ARGV-element 1 (since ARGV-element 0
      is the program name); the sequence of previously skipped
@@ -424,13 +420,8 @@
    long-named options.  */
 
 int
-_getopt_internal (argc, argv, optstring, longopts, longind, long_only)
-     int argc;
-     char *const *argv;
-     const char *optstring;
-     const struct option *longopts;
-     int *longind;
-     int long_only;
+_getopt_internal (int argc, char *const *argv, const char *optstring, 
+						const struct option *longopts, int *longind, int long_only)
 {
   optarg = NULL;
 
@@ -722,10 +713,7 @@
 }
 
 int
-getopt (argc, argv, optstring)
-     int argc;
-     char *const *argv;
-     const char *optstring;
+getopt (int argc, char *const *argv, const char *optstring)
 {
   return _getopt_internal (argc, argv, optstring,
 			   (const struct option *) 0,
@@ -741,9 +729,7 @@
    the above definition of `getopt'.  */
 
 int
-main (argc, argv)
-     int argc;
-     char **argv;
+main (int argc, char *argv[])
 {
   int c;
   int digit_optind = 0;

Modified: nonameyet/branches/cleanup/mkisofs/getopt1.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/getopt1.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/getopt1.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -83,12 +83,8 @@
 #endif
 
 int
-getopt_long (argc, argv, options, long_options, opt_index)
-     int argc;
-     char *const *argv;
-     const char *options;
-     const struct option *long_options;
-     int *opt_index;
+getopt_long (int argc, char *const *argv, const char *options, 
+				 const struct option *long_options, int *opt_index)
 {
   return _getopt_internal (argc, argv, options, long_options, opt_index, 0);
 }
@@ -99,12 +95,8 @@
    instead.  */
 
 int
-getopt_long_only (argc, argv, options, long_options, opt_index)
-     int argc;
-     char *const *argv;
-     const char *options;
-     const struct option *long_options;
-     int *opt_index;
+getopt_long_only (int argc, char *const *argv, const char *options, 
+						const struct option *long_options, int *opt_index)
 {
   return _getopt_internal (argc, argv, options, long_options, opt_index, 1);
 }
@@ -117,9 +109,7 @@
 #include <stdio.h>
 
 int
-main (argc, argv)
-     int argc;
-     char **argv;
+main (int argc, char *argv[])
 {
   int c;
   int digit_optind = 0;

Modified: nonameyet/branches/cleanup/mkisofs/hash.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/hash.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/hash.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -68,21 +68,20 @@
 
 static struct file_hash *hash_table[NR_HASH] = {0, };
 
-EXPORT	void		add_hash	__PR((struct directory_entry *spnt));
-EXPORT	struct file_hash *find_hash	__PR((dev_t dev, ino_t inode));
-EXPORT	void		flush_hash	__PR((void));
-EXPORT	void		add_directory_hash __PR((dev_t dev, ino_t inode));
-EXPORT	struct file_hash *find_directory_hash __PR((dev_t dev, ino_t inode));
-LOCAL	unsigned int	name_hash	__PR((const char *name));
-EXPORT	void		add_file_hash	__PR((struct directory_entry *de));
-EXPORT	struct directory_entry *find_file_hash __PR((char *name));
-LOCAL	BOOL		isoname_endsok	__PR((char *name));
-EXPORT	int		delete_file_hash __PR((struct directory_entry *de));
-EXPORT	void		flush_file_hash	__PR((void));
+void		add_hash(struct directory_entry *spnt);
+struct file_hash *find_hash(dev_t dev, ino_t inode);
+void		flush_hash(void);
+void		add_directory_hash(dev_t dev, ino_t inode);
+struct file_hash *find_directory_hash(dev_t dev, ino_t inode);
+static	unsigned int	name_hash(const char *name);
+void		add_file_hash(struct directory_entry *de);
+struct directory_entry *find_file_hash(char *name);
+static	BOOL		isoname_endsok(char *name);
+int		delete_file_hash(struct directory_entry *de);
+void		flush_file_hash(void);
 
-EXPORT void
-add_hash(spnt)
-	struct directory_entry	*spnt;
+void
+add_hash(struct directory_entry *spnt)
 {
 	struct file_hash *s_hash;
 	unsigned int    hash_number;
@@ -126,15 +125,8 @@
 	hash_table[hash_number] = s_hash;
 }
 
-#ifdef	PROTOTYPES
-EXPORT struct file_hash *
+struct file_hash *
 find_hash(dev_t dev, ino_t inode)
-#else
-EXPORT struct file_hash *
-find_hash(dev, inode)
-	dev_t	dev;
-	ino_t	inode;
-#endif
 {
 	unsigned int    hash_number;
 	struct file_hash *spnt;
@@ -158,7 +150,7 @@
  * based on flush_file_hash() below - needed as we want to re-use the
  * file hash table.
  */
-EXPORT void
+void
 flush_hash()
 {
 	struct file_hash	*fh;
@@ -178,15 +170,8 @@
 
 static struct file_hash *directory_hash_table[NR_HASH] = {0, };
 
-#ifdef	PROTOTYPES
-EXPORT void
+void
 add_directory_hash(dev_t dev, ino_t inode)
-#else
-EXPORT void
-add_directory_hash(dev, inode)
-	dev_t	dev;
-	ino_t	inode;
-#endif
 {
 	struct file_hash *s_hash;
 	unsigned int    hash_number;
@@ -205,15 +190,8 @@
 	directory_hash_table[hash_number] = s_hash;
 }
 
-#ifdef	PROTOTYPES
-EXPORT struct file_hash *
+struct file_hash *
 find_directory_hash(dev_t dev, ino_t inode)
-#else
-EXPORT struct file_hash *
-find_directory_hash(dev, inode)
-	dev_t	dev;
-	ino_t	inode;
-#endif
 {
 	unsigned int    hash_number;
 	struct file_hash *spnt;
@@ -245,9 +223,8 @@
 /*
  * Find the hash bucket for this name.
  */
-LOCAL unsigned int
-name_hash(name)
-	const char	*name;
+static unsigned int
+name_hash(const char *name)
 {
 	unsigned int	hash = 0;
 	const char	*p;
@@ -268,9 +245,8 @@
 	return (hash % NR_NAME_HASH);
 }
 
-EXPORT void
-add_file_hash(de)
-	struct directory_entry	*de;
+void
+add_file_hash(struct directory_entry *de)
 {
 	struct name_hash	*new;
 	int			hash;
@@ -285,9 +261,8 @@
 	name_hash_table[hash] = new;
 }
 
-EXPORT struct directory_entry *
-find_file_hash(name)
-	register char			*name;
+struct directory_entry *
+find_file_hash(register char *name)
 {
 	register char			*p1;
 	register char			*p2;
@@ -352,9 +327,8 @@
 		((p)[0] == ';' && (p)[1] == '1' && (p)[2] == '\0') || \
 		isoname_endsok(p))
 
-LOCAL BOOL
-isoname_endsok(name)
-	char	*name;
+static BOOL
+isoname_endsok(char *name)
 {
 	int	i;
 	char	*p;
@@ -374,9 +348,8 @@
 	return (TRUE);
 }
 
-EXPORT int
-delete_file_hash(de)
-	struct directory_entry	*de;
+int
+delete_file_hash(struct directory_entry *de)
 {
 	struct name_hash	*nh;
 	struct name_hash	*prev;
@@ -399,7 +372,7 @@
 	return (0);
 }
 
-EXPORT void
+void
 flush_file_hash()
 {
 	struct name_hash	*nh;

Modified: nonameyet/branches/cleanup/mkisofs/ifo_read.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/ifo_read.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/ifo_read.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -60,17 +60,15 @@
 #define MSGESEEK "Failed to seek VIDEO_TS.IFO\n"
 #define MSGEOPEN "Failed to open VIDEO_TS.IFO\n"
 
-LOCAL	ifo_handle_t *	ifoReadVTSI	__PR((int file, ifo_handle_t * ifofile));
-LOCAL	ifo_handle_t *	ifoReadVGMI	__PR((int file, ifo_handle_t * ifofile));
-EXPORT	ifo_handle_t *	ifoOpen		__PR((dvd_reader_t *dvd, int title));
-LOCAL	void		ifoFree_TT_SRPT	__PR((ifo_handle_t *ifofile));
-EXPORT	void		ifoClose	__PR((ifo_handle_t * ifofile));
+static	ifo_handle_t *ifoReadVTSI(int file, ifo_handle_t * ifofile);
+static	ifo_handle_t *ifoReadVGMI(int file, ifo_handle_t * ifofile);
+ifo_handle_t *ifoOpen(dvd_reader_t *dvd, int title);
+static	void		ifoFree_TT_SRPT(ifo_handle_t *ifofile);
+void		ifoClose(ifo_handle_t * ifofile);
 
 
-LOCAL ifo_handle_t *
-ifoReadVTSI(file, ifofile)
-	int file;
-	ifo_handle_t * ifofile;
+static ifo_handle_t *
+ifoReadVTSI(int file, ifo_handle_t *ifofile)
 {
 	off_t offset;
 	UInt32_t sector;
@@ -210,10 +208,8 @@
 }
 
 
-LOCAL ifo_handle_t *
-ifoReadVGMI(file, ifofile)
-	int file;
-	ifo_handle_t * ifofile;
+static ifo_handle_t *
+ifoReadVGMI(int file, ifo_handle_t *ifofile)
 {
 	off_t	offset;
 	Uint	counter;
@@ -457,10 +453,8 @@
 	return (ifofile);
 }
 
-EXPORT ifo_handle_t *
-ifoOpen(dvd, title)
-	dvd_reader_t *dvd;
-	int title;
+ifo_handle_t *
+ifoOpen(dvd_reader_t *dvd, int title)
 {
 	/* The main ifofile structure */
 	ifo_handle_t *ifofile;
@@ -531,9 +525,8 @@
 	}
 }
 
-LOCAL void
-ifoFree_TT_SRPT(ifofile)
-	ifo_handle_t *ifofile;
+static void
+ifoFree_TT_SRPT(ifo_handle_t *ifofile)
 {
 	if (!ifofile)
 		return;
@@ -547,9 +540,8 @@
 	}
 }
 
-EXPORT void
-ifoClose(ifofile)
-	ifo_handle_t * ifofile;
+void
+ifoClose(ifo_handle_t *ifofile)
 {
 
 	if (!ifofile)

Modified: nonameyet/branches/cleanup/mkisofs/ifo_read.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/ifo_read.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/ifo_read.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -66,14 +66,14 @@
  * manager IFO file is read.
  * Returns a handle to a tiny parsed fraction of a IFO strcuture
  */
-extern	ifo_handle_t *ifoOpen	__PR((dvd_reader_t *, int));
+extern	ifo_handle_t *ifoOpen(dvd_reader_t *, int);
 
 
 /*
  * ifoClose(ifofile);
  * Cleans up the IFO information. This will free all data allocated.
  */
-extern	void ifoClose		__PR((ifo_handle_t *));
+extern	void ifoClose(ifo_handle_t *);
 
 #ifdef __cplusplus
 };

Modified: nonameyet/branches/cleanup/mkisofs/joliet.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/joliet.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/joliet.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -120,64 +120,53 @@
 };
 
 #ifdef	UDF
-#     ifdef USE_ICONV
-       size_t
-#     else
-       void
-#     endif
-		convert_to_unicode	__PR((unsigned char *buffer,
-		int size, char *source, struct unls_table *inls));
-	int	joliet_strlen		__PR((const char *string, struct unls_table *inls));
+#ifdef USE_ICONV
+size_t
 #else
-#     ifdef USE_ICONV
-       static size_t
-#     else
-       static void
+void
 #endif
-       convert_to_unicode	__PR((unsigned char *buffer,
-		int size, char *source, struct unls_table *inls));
-static int	joliet_strlen		__PR((const char *string, struct nls_table *inls));
+convert_to_unicode(unsigned char *buffer, int size, char *source, 
+						 struct unls_table *inls);
+int	joliet_strlen(const char *string, struct unls_table *inls);
+#else
+#ifdef USE_ICONV
+static size_t
+#else
+static void
 #endif
-static void	get_joliet_vol_desc	__PR((struct iso_primary_descriptor *jvol_desc));
-static void	assign_joliet_directory_addresses __PR((struct directory *node));
-static void	build_jpathlist		__PR((struct directory *node));
-static int	joliet_compare_paths	__PR((void const *r, void const *l));
-static int	generate_joliet_path_tables __PR((void));
-static void	generate_one_joliet_directory __PR((struct directory *dpnt,
-						FILE *outfile));
-static int	joliet_sort_n_finish	__PR((struct directory *this_dir));
+convert_to_unicode(unsigned char *buffer, int size, char *source, 
+						 struct unls_table *inls);
+static int	joliet_strlen(const char *string, struct nls_table *inls);
+#endif
+static void	get_joliet_vol_desc(struct iso_primary_descriptor *jvol_desc);
+static void	assign_joliet_directory_addresses(struct directory *node);
+static void	build_jpathlist(struct directory *node);
+static int	joliet_compare_paths(void const *r, void const *l);
+static int	generate_joliet_path_tables(void);
+static void	generate_one_joliet_directory(struct directory *dpnt, 
+														FILE *outfile);
+static int	joliet_sort_n_finish(struct directory *this_dir);
+static int	joliet_compare_dirs(const void *rr, const void *ll);
+static int	joliet_sort_directory(struct directory_entry **sort_dir);
+int	joliet_sort_tree(struct directory *node);
+static void	generate_joliet_directories(struct directory *node, FILE *outfile);
+static int	jpathtab_write(FILE *outfile);
+static int	jdirtree_size(int starting_extent);
+static int	jroot_gen(void);
+static int	jdirtree_write(FILE *outfile);
+static int	jvd_write(FILE *outfile);
+static int	jpathtab_size(int starting_extent);
 
-static int	joliet_compare_dirs	__PR((const void *rr, const void *ll));
-
-static int	joliet_sort_directory	__PR((struct directory_entry **sort_dir));
-	int	joliet_sort_tree	__PR((struct directory *node));
-static void	generate_joliet_directories __PR((struct directory *node,
-						FILE *outfile));
-static int	jpathtab_write		__PR((FILE *outfile));
-static int	jdirtree_size		__PR((int starting_extent));
-static int	jroot_gen		__PR((void));
-static int	jdirtree_write		__PR((FILE *outfile));
-static int	jvd_write		__PR((FILE *outfile));
-static int	jpathtab_size		__PR((int starting_extent));
-
 /*
  *	conv_charset: convert to/from charsets via Unicode.
  *
  *	Any unknown character is set to '_'
  *
  */
-#ifdef	PROTOTYPES
 unsigned char
 conv_charset(unsigned char c,
 	struct unls_table *inls,
 	struct unls_table *onls)
-#else
-unsigned char
-conv_charset(c, inls, onls)
-	unsigned char c;
-	struct unls_table *inls;
-	struct unls_table *onls;
-#endif
 {
 	unsigned char	uh;
 	unsigned char	ul;
@@ -240,11 +229,8 @@
 static void
 #	endif
 #endif
-convert_to_unicode(buffer, size, source, inls)
-	unsigned char	*buffer;
-	int		size;
-	char		*source;
-	struct unls_table *inls;
+convert_to_unicode(unsigned char *buffer, int size, char *source, 
+						 struct unls_table *inls)
 {
 	unsigned char	*tmpbuf;
 	int		i;
@@ -384,9 +370,7 @@
 #else
 static int
 #endif
-joliet_strlen(string, inls)
-	const char	*string;
-	struct unls_table *inls;
+joliet_strlen(const char *string, struct unls_table *inls)
 {
 	int		rtn;
 
@@ -451,8 +435,7 @@
  *			appropriate fields.
  */
 static void
-get_joliet_vol_desc(jvol_desc)
-	struct iso_primary_descriptor	*jvol_desc;
+get_joliet_vol_desc(struct iso_primary_descriptor *jvol_desc)
 {
 	jvol_desc->type[0] = ISO_VD_SUPPLEMENTARY;
 
@@ -502,8 +485,7 @@
 }
 
 static void
-assign_joliet_directory_addresses(node)
-	struct directory	*node;
+assign_joliet_directory_addresses(struct directory *node)
 {
 	int		dir_size;
 	struct directory *dpnt;
@@ -533,8 +515,7 @@
 }
 
 static void
-build_jpathlist(node)
-	struct directory	*node;
+build_jpathlist(struct directory *node)
 {
 	struct directory	*dpnt;
 
@@ -551,9 +532,7 @@
 }/* build_jpathlist(... */
 
 static int
-joliet_compare_paths(r, l)
-	void const	*r;
-	void const	*l;
+joliet_compare_paths(void const *r, void const *l)
 {
 	struct directory const *ll = *(struct directory * const *) l;
 	struct directory const *rr = *(struct directory * const *) r;
@@ -826,9 +805,7 @@
 }/* generate_path_tables(... */
 
 static void
-generate_one_joliet_directory(dpnt, outfile)
-	struct directory	*dpnt;
-	FILE			*outfile;
+generate_one_joliet_directory(struct directory *dpnt, FILE *outfile)
 {
 	unsigned int		dir_index;
 	char			*directory_buffer;
@@ -1008,8 +985,7 @@
 }/* generate_one_joliet_directory(... */
 
 static int
-joliet_sort_n_finish(this_dir)
-	struct directory	*this_dir;
+joliet_sort_n_finish(struct directory *this_dir)
 {
 	struct directory_entry	*s_entry;
 	int			status = 0;
@@ -1131,9 +1107,7 @@
  * regular name of the file, not the 8.3 version.
  */
 static int
-joliet_compare_dirs(rr, ll)
-	const void	*rr;
-	const void	*ll;
+joliet_compare_dirs(const void *rr, const void *ll)
 {
 	char		*rpnt,
 			*lpnt;
@@ -1292,8 +1266,7 @@
  * Notes:		Returns 0 if OK, returns > 0 if an error occurred.
  */
 static int
-joliet_sort_directory(sort_dir)
-	struct directory_entry	**sort_dir;
+joliet_sort_directory(struct directory_entry **sort_dir)
 {
 	int			dcount = 0;
 	int			i;
@@ -1345,8 +1318,7 @@
 }
 
 int
-joliet_sort_tree(node)
-	struct directory	*node;
+joliet_sort_tree(struct directory *node)
 {
 	struct directory	*dpnt;
 	int			ret = 0;
@@ -1369,9 +1341,7 @@
 }
 
 static void
-generate_joliet_directories(node, outfile)
-	struct directory	*node;
-	FILE			*outfile;
+generate_joliet_directories(struct directory *node, FILE *outfile)
 {
 	struct directory *dpnt;
 
@@ -1402,8 +1372,7 @@
  * Function to write the EVD for the disc.
  */
 static int
-jpathtab_write(outfile)
-	FILE	*outfile;
+jpathtab_write(FILE *outfile)
 {
 	/* Next we write the path tables */
 	jtwrite(jpath_table_l, jpath_blocks << 11, 1, 0, FALSE);
@@ -1420,8 +1389,7 @@
 }
 
 static int
-jdirtree_size(starting_extent)
-	int	starting_extent;
+jdirtree_size(int starting_extent)
 {
 	assign_joliet_directory_addresses(root);
 	return (0);
@@ -1445,8 +1413,7 @@
 }
 
 static int
-jdirtree_write(outfile)
-	FILE	*outfile;
+jdirtree_write(FILE *outfile)
 {
 	generate_joliet_directories(root, outfile);
 	return (0);
@@ -1456,8 +1423,7 @@
  * Function to write the EVD for the disc.
  */
 static int
-jvd_write(outfile)
-	FILE	*outfile;
+jvd_write(FILE *outfile)
 {
 	struct iso_primary_descriptor jvol_desc;
 
@@ -1474,8 +1440,7 @@
  * Functions to describe padding block at the start of the disc.
  */
 static int
-jpathtab_size(starting_extent)
-	int	starting_extent;
+jpathtab_size(int starting_extent)
 {
 	jpath_table[0] = starting_extent;
 	jpath_table[1] = 0;

Modified: nonameyet/branches/cleanup/mkisofs/mac_label.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/mac_label.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/mac_label.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -62,16 +62,15 @@
 #include "apple.h"
 
 #ifdef PREP_BOOT
-void	gen_prepboot_label	__PR((unsigned char *ml));
+void	gen_prepboot_label(unsigned char *ml);
 
 #endif	/* PREP_BOOT */
-int	gen_mac_label		__PR((defer * mac_boot));
-int	autostart		__PR((void));
+int	gen_mac_label(defer * mac_boot);
+int	autostart(void);
 
 #ifdef PREP_BOOT
 void
-gen_prepboot_label(ml)
-	unsigned char	*ml;
+gen_prepboot_label(unsigned char *ml)
 {
 	struct directory_entry *de;
 	int		i = 0;
@@ -166,8 +165,7 @@
 #endif	/* PREP_BOOT */
 
 int
-gen_mac_label(mac_boot)
-	defer		*mac_boot;
+gen_mac_label(defer *mac_boot)
 {
 	FILE		*fp;
 	MacLabel	*mac_label;

Modified: nonameyet/branches/cleanup/mkisofs/match.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/match.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/match.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -64,10 +64,8 @@
 
 static sort_match	*s_mats;
 
-EXPORT int
-add_sort_match(fn, val)
-	char	*fn;
-	int	val;
+int
+add_sort_match(char *fn, int val)
 {
 	sort_match *s_mat;
 
@@ -101,9 +99,8 @@
 	return (1);
 }
 
-EXPORT void
-add_sort_list(file)
-	char	*file;
+void
+add_sort_list(char *file)
 {
 	FILE	*fp;
 	char	name[4096];
@@ -148,10 +145,8 @@
 	fclose(fp);
 }
 
-EXPORT int
-sort_matches(fn, val)
-	char	*fn;
-	int	val;
+int
+sort_matches(char *fn, int val)
 {
 	register sort_match	*s_mat;
 
@@ -163,7 +158,7 @@
 	return (val); /* not found - default sort value */
 }
 
-EXPORT void
+void
 del_sort()
 {
 	register sort_match * s_mat, *s_mat1;
@@ -184,10 +179,8 @@
 #endif /* SORTING */
 
 
-EXPORT int
-gen_add_match(fn, n)
-	char	*fn;
-	int	n;
+int
+gen_add_match(char *fn, int n)
 {
 	match	*mat;
 
@@ -219,10 +212,8 @@
 	return (1);
 }
 
-EXPORT void
-gen_add_list(file, n)
-	char	*file;
-	int	n;
+void
+gen_add_list(char *file, int n)
 {
 	FILE	*fp;
 	char	name[4096];
@@ -254,10 +245,8 @@
 	fclose(fp);
 }
 
-EXPORT int
-gen_matches(fn, n)
-	char	*fn;
-	int	n;
+int
+gen_matches(char *fn, int n)
 {
 	register match * mat;
 
@@ -272,9 +261,8 @@
 	return (0);			/* not found -> not excluded */
 }
 
-EXPORT int
-gen_ishidden(n)
-	int	n;
+int
+gen_ishidden(int n)
 {
 	if (n >= MAX_MAT)
 		return (0);
@@ -282,9 +270,8 @@
 	return ((int)(mats[n] != 0));
 }
 
-EXPORT void
-gen_del_match(n)
-	int	n;
+void
+gen_del_match(int n)
 {
 	register match	*mat;
 	register match 	*mat1;

Modified: nonameyet/branches/cleanup/mkisofs/match.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/match.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/match.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -41,17 +41,17 @@
 #define	MAX_MAT		4
 #endif /* APPLE_HYB */
 
-extern int	gen_add_match	__PR((char *fn, int n));
-extern int	gen_matches	__PR((char *fn, int n));
-extern void	gen_add_list	__PR((char *fn, int n));
-extern int	gen_ishidden	__PR((int n));
-extern void	gen_del_match	__PR((int n));
+extern int	gen_add_match(char *fn, int n);
+extern int	gen_matches(char *fn, int n);
+extern void	gen_add_list(char *fn, int n);
+extern int	gen_ishidden(int n);
+extern void	gen_del_match(int n);
 
 #ifdef SORTING
-extern int	add_sort_match	__PR((char *fn, int val));
-extern void	add_sort_list	__PR((char *fn));
-extern int	sort_matches	__PR((char *fn, int val));
-extern void	del_sort	__PR((void));
+extern int	add_sort_match(char *fn, int val);
+extern void	add_sort_list(char *fn);
+extern int	sort_matches(char *fn, int val);
+extern void	del_sort(void);
 #endif /* SORTING */
 
 /*

Modified: nonameyet/branches/cleanup/mkisofs/md5.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/md5.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/md5.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -61,17 +61,14 @@
    surprised if they were a performance bottleneck for MD5.  */
 
 static mk_uint32
-getu32 (addr)
-     const unsigned char *addr;
+getu32 (const unsigned char *addr)
 {
 	return (((((unsigned long)addr[3] << 8) | addr[2]) << 8)
 		| addr[1]) << 8 | addr[0];
 }
 
 static void
-putu32 (data, addr)
-     mk_uint32 data;
-     unsigned char *addr;
+putu32 (mk_uint32 data, unsigned char *addr)
 {
 	addr[0] = (unsigned char)data;
 	addr[1] = (unsigned char)(data >> 8);
@@ -84,8 +81,7 @@
  * initialization constants.
  */
 void
-mk_MD5Init (ctx)
-     struct mk_MD5Context *ctx;
+mk_MD5Init (struct mk_MD5Context *ctx)
 {
 	ctx->buf[0] = 0x67452301;
 	ctx->buf[1] = 0xefcdab89;
@@ -101,10 +97,7 @@
  * of bytes.
  */
 void
-mk_MD5Update (ctx, buf, len)
-     struct mk_MD5Context *ctx;
-     unsigned char const *buf;
-     unsigned len;
+mk_MD5Update (struct mk_MD5Context *ctx, unsigned char const *buf, unsigned len)
 {
 	mk_uint32 t;
 
@@ -152,9 +145,7 @@
  * 1 0* (64-bit count of bits processed, MSB-first)
  */
 void
-mk_MD5Final (digest, ctx)
-     unsigned char digest[16];
-     struct mk_MD5Context *ctx;
+mk_MD5Final (unsigned char digest[16], struct mk_MD5Context *ctx)
 {
 	unsigned count;
 	unsigned char *p;
@@ -215,9 +206,7 @@
  * the data and converts bytes into longwords for this routine.
  */
 void
-mk_MD5Transform (buf, inraw)
-     mk_uint32 buf[4];
-     const unsigned char inraw[64];
+mk_MD5Transform (mk_uint32 buf[4], const unsigned char inraw[64])
 {
 	register mk_uint32 a, b, c, d;
 	mk_uint32 in[16];
@@ -386,7 +375,7 @@
 #include <stdio.h>
 
 int
-main (int argc, char **argv)
+main (int argc, char *argv[])
 {
 	struct mk_MD5Context context;
 	unsigned char checksum[16];

Modified: nonameyet/branches/cleanup/mkisofs/mkisofs.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/mkisofs.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/mkisofs.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -486,9 +486,9 @@
 
 #endif	/* APPLE_HYB */
 
-LOCAL int	save_pname = 0;
+static int	save_pname = 0;
 
-LOCAL const struct ld_option ld_options[] =
+static const struct ld_option ld_options[] =
 {
 	{{"nobak", no_argument, NULL, OPTION_NOBAK},
 	'\0', NULL, "Do not include backup files", ONE_DASH},
@@ -856,21 +856,19 @@
 
 #define	OPTION_COUNT (sizeof ld_options / sizeof (ld_options[0]))
 
-LOCAL	void	read_rcfile	__PR((char *appname));
-LOCAL	void	susage		__PR((int excode));
-LOCAL	void	usage		__PR((int excode));
-EXPORT	int	iso9660_date	__PR((char *result, time_t crtime));
-LOCAL	void	hide_reloc_dir	__PR((void));
-LOCAL	char *	get_pnames	__PR((int argc, char **argv, int opt,
-					char *pname, int pnsize, FILE * fp));
-EXPORT	int	main		__PR((int argc, char **argv));
-EXPORT	char *	findgequal	__PR((char *s));
-LOCAL	char *	escstrcpy	__PR((char *to, char *from));
-EXPORT	void *	e_malloc	__PR((size_t size));
+static	void	read_rcfile(char *appname);
+static	void	susage(int excode);
+static	void	usage(int excode);
+int	iso9660_date(char *result, time_t crtime);
+static	void	hide_reloc_dir(void);
+static	char *get_pnames(int argc, char **argv, int opt, char *pname, 
+								  int pnsize, FILE *fp);
+char *findgequal(char *s);
+static	char *escstrcpy(char *to, char *from);
+void *e_malloc(size_t size);
 
-LOCAL void
-read_rcfile(appname)
-	char		*appname;
+static void
+read_rcfile(char *appname)
 {
 	FILE		*rcfile = (FILE *) NULL;
 	struct rcopts	*rco;
@@ -1043,9 +1041,8 @@
 #define	FALSE 0
 #endif
 
-LOCAL void
-susage(excode)
-	int		excode;
+static void
+susage(int excode)
 {
 	const char	*program_name = "mkisofs";
 
@@ -1061,9 +1058,8 @@
 	exit(excode);
 }
 
-LOCAL void
-usage(excode)
-	int		excode;
+static void
+usage(int excode)
 {
 	const char	*program_name = "mkisofs";
 
@@ -1170,10 +1166,8 @@
  * with DST,  I guess).  The Linux iso9660 filesystem has had the sign
  * of this wrong for ages (mkisofs had it wrong too for the longest time).
  */
-EXPORT int
-iso9660_date(result, crtime)
-	char	*result;
-	time_t	crtime;
+int
+iso9660_date(char *result, time_t crtime)
 {
 	struct tm	*local;
 
@@ -1209,7 +1203,7 @@
 }
 
 /* hide "./rr_moved" if all its contents are hidden */
-LOCAL void
+static void
 hide_reloc_dir()
 {
 	struct directory_entry *s_entry;
@@ -1231,14 +1225,8 @@
 /*
  * get pathnames from the command line, and then from given file
  */
-LOCAL char *
-get_pnames(argc, argv, opt, pname, pnsize, fp)
-	int	argc;
-	char	**argv;
-	int	opt;
-	char	*pname;
-	int	pnsize;
-	FILE	*fp;
+static char *
+get_pnames(int argc, char **argv, int opt, char *pname, int pnsize, FILE *fp)
 {
 	int	len;
 
@@ -1267,10 +1255,8 @@
 
 extern char	*cdrecord_data;
 
-EXPORT int
-main(argc, argv)
-	int		argc;
-	char		**argv;
+int
+main(int argc, char *argv[])
 {
 	struct directory_entry de;
 
@@ -3708,9 +3694,8 @@
 /*
  * Find unescaped equal sign in graft pointer string.
  */
-EXPORT char *
-findgequal(s)
-	char	*s;
+char *
+findgequal(char *s)
 {
 	char	*p = s;
 
@@ -3725,10 +3710,8 @@
 /*
  * Find unescaped equal sign in string.
  */
-LOCAL char *
-escstrcpy(to, from)
-	char	*to;
-	char	*from;
+static char *
+escstrcpy(char *to, char *from)
 {
 	char	*p = to;
 
@@ -3751,9 +3734,8 @@
 	return (to);
 }
 
-EXPORT void *
-e_malloc(size)
-	size_t		size;
+void *
+e_malloc(size_t size)
 {
 	void		*pt = 0;
 

Modified: nonameyet/branches/cleanup/mkisofs/mkisofs.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/mkisofs.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/mkisofs.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -176,9 +176,9 @@
  */
 struct output_fragment {
 	struct output_fragment *of_next;
-	int		(*of_size)	__PR((int));
-	int		(*of_generate)	__PR((void));
-	int		(*of_write)	__PR((FILE *));
+	int		(*of_size)(int);
+	int		(*of_generate)(void);
+	int		(*of_write)(FILE *);
 	char		*of_name;			/* Textual description */
 	unsigned int	of_start_extent;		/* For consist check */
 };
@@ -433,98 +433,93 @@
 #endif /* SORTING */
 
 /* tree.c */
-extern int stat_filter __PR((char *, struct stat *));
-extern int lstat_filter __PR((char *, struct stat *));
-extern int sort_tree __PR((struct directory *));
+extern int stat_filter(char *, struct stat *);
+extern int lstat_filter(char *, struct stat *);
+extern int sort_tree(struct directory *);
 extern struct directory *
-		find_or_create_directory __PR((struct directory *,
-				const char *,
-				struct directory_entry * self, int));
-extern void	finish_cl_pl_entries __PR((void));
-extern int	scan_directory_tree __PR((struct directory * this_dir,
-				char *path,
-				struct directory_entry * self));
+find_or_create_directory(struct directory *, const char *, 
+								 struct directory_entry *self, int);
+extern void	finish_cl_pl_entries(void);
+extern int	scan_directory_tree(struct directory *this_dir, char *path,
+										  struct directory_entry *self);
 
 #ifdef APPLE_HYB
-extern int	insert_file_entry __PR((struct directory *, char *,
-				char *, int));
-
+extern int	insert_file_entry(struct directory *, char *, char *, int);
 #else
-extern int	insert_file_entry __PR((struct directory *, char *,
-				char *));
-
+extern int	insert_file_entry(struct directory *, char *, char *);
 #endif	/* APPLE_HYB */
 
-extern void generate_iso9660_directories __PR((struct directory *, FILE *));
-extern void dump_tree __PR((struct directory * node));
-extern struct directory_entry *search_tree_file __PR((struct
-				directory * node, char *filename));
-extern void update_nlink_field __PR((struct directory * node));
-extern void init_fstatbuf __PR((void));
+extern void generate_iso9660_directories(struct directory *, FILE *);
+extern void dump_tree(struct directory * node);
+extern struct directory_entry *
+search_tree_file(struct directory * node, char *filename);
+extern void update_nlink_field(struct directory * node);
+extern void init_fstatbuf(void);
 extern struct stat root_statbuf;
 extern struct stat fstatbuf;
 
 /* eltorito.c */
-extern void init_boot_catalog __PR((const char *path));
-extern void insert_boot_cat __PR((void));
-extern void get_boot_entry	__PR((void));
-extern void new_boot_entry	__PR((void));
+extern void init_boot_catalog(const char *path);
+extern void insert_boot_cat(void);
+extern void get_boot_entry(void);
+extern void new_boot_entry(void);
 
 /* boot.c */
-extern void sparc_boot_label __PR((char *label));
-extern void sunx86_boot_label __PR((char *label));
-extern void scan_sparc_boot __PR((char *files));
-extern void scan_sunx86_boot __PR((char *files));
-extern int make_sun_label __PR((void));
-extern int make_sunx86_label __PR((void));
+extern void sparc_boot_label(char *label);
+extern void sunx86_boot_label(char *label);
+extern void scan_sparc_boot(char *files);
+extern void scan_sunx86_boot(char *files);
+extern int make_sun_label(void);
+extern int make_sunx86_label(void);
 
 /* boot-alpha.c */
-extern int add_boot_alpha_filename __PR((char *filename));
+extern int add_boot_alpha_filename(char *filename);
 
 /* boot-hppa.c */
-extern int add_boot_hppa_cmdline    __PR((char *cmdline));
-extern int add_boot_hppa_kernel_32  __PR((char *filename));
-extern int add_boot_hppa_kernel_64  __PR((char *filename));
-extern int add_boot_hppa_bootloader __PR((char *filename));
-extern int add_boot_hppa_ramdisk    __PR((char *filename));
+extern int add_boot_hppa_cmdline(char *cmdline);
+extern int add_boot_hppa_kernel_32(char *filename);
+extern int add_boot_hppa_kernel_64(char *filename);
+extern int add_boot_hppa_bootloader(char *filename);
+extern int add_boot_hppa_ramdisk(char *filename);
 
 /* boot-mips.c */
-extern int add_boot_mips_filename __PR((char *filename));
+extern int add_boot_mips_filename(char *filename);
 
 /* boot-mipsel.c */
-extern int add_boot_mipsel_filename  __PR((char *filename));
+extern int add_boot_mipsel_filename(char *filename);
 
 /* rsync.c */
-extern unsigned long long rsync64   __PR((unsigned char *mem, size_t size));
+extern unsigned long long rsync64(unsigned char *mem, size_t size);
 
 /* write.c */
-extern int get_731 __PR((char *));
-extern int get_732 __PR((char *));
-extern int get_733 __PR((char *));
-extern int isonum_733 __PR((unsigned char *));
-extern void set_723 __PR((char *, unsigned int));
-extern void set_731 __PR((char *, unsigned int));
-extern void set_721 __PR((char *, unsigned int));
-extern void set_733 __PR((char *, unsigned int));
-extern int sort_directory __PR((struct directory_entry **, int));
-extern void generate_one_directory __PR((struct directory *, FILE *));
-extern void memcpy_max __PR((char *, char *, int));
-extern int oneblock_size __PR((int starting_extent));
+extern int get_731(char *);
+extern int get_732(char *);
+extern int get_733(char *);
+extern int isonum_733(unsigned char *);
+extern void set_723(char *, unsigned int);
+extern void set_731(char *, unsigned int);
+extern void set_721(char *, unsigned int);
+extern void set_733(char *, unsigned int);
+extern int sort_directory(struct directory_entry **, int);
+extern void generate_one_directory(struct directory *, FILE *);
+extern void memcpy_max(char *, char *, int);
+extern int oneblock_size(int starting_extent);
 extern struct iso_primary_descriptor vol_desc;
-extern void xfwrite __PR((void *buffer, int size, int count, FILE * file, int submode, BOOL islast));
-extern void set_732 __PR((char *pnt, unsigned int i));
-extern void set_722 __PR((char *pnt, unsigned int i));
-extern void outputlist_insert __PR((struct output_fragment * frag));
+extern void xfwrite(void *buffer, int size, int count, FILE *file, int submode,
+						  BOOL islast);
+extern void set_732(char *pnt, unsigned int i);
+extern void set_722(char *pnt, unsigned int i);
+extern void outputlist_insert(struct output_fragment * frag);
 
 #ifdef APPLE_HYB
-extern Ulong get_adj_size __PR((int Csize));
-extern int adj_size __PR((int Csize, int start_extent, int extra));
-extern void adj_size_other __PR((struct directory * dpnt));
-extern int insert_padding_file __PR((int size));
-extern int gen_mac_label __PR((struct deferred_write *));
+extern Ulong get_adj_size(int Csize);
+extern int adj_size(int Csize, int start_extent, int extra);
+extern void adj_size_other(struct directory * dpnt);
+extern int insert_padding_file(int size);
+extern int gen_mac_label(struct deferred_write *);
 
 #ifdef PREP_BOOT
-extern void gen_prepboot_label __PR((unsigned char *));
+extern void gen_prepboot_label(unsigned char *);
 
 #endif	/* PREP_BOOT */
 #endif	/* APPLE_HYB */
@@ -532,114 +527,112 @@
 /* multi.c */
 
 extern FILE	*in_image;
-extern int open_merge_image __PR((char *path));
-extern int close_merge_image __PR((void));
+extern int open_merge_image(char *path);
+extern int close_merge_image(void);
 extern struct iso_directory_record *
-			merge_isofs __PR((char *path));
-extern unsigned char	*parse_xa __PR((unsigned char *pnt, int *lenp,
-				struct directory_entry * dpnt));
-extern int	rr_flags	__PR((struct iso_directory_record *idr));
-extern int merge_previous_session __PR((struct directory *,
-				struct iso_directory_record *, char *, char *));
-extern int get_session_start __PR((int *));
+merge_isofs(char *path);
+extern unsigned char	*parse_xa(unsigned char *pnt, int *lenp,
+										 struct directory_entry *dpnt);
+extern int	rr_flags(struct iso_directory_record *idr);
+extern int merge_previous_session(struct directory *, 
+											 struct iso_directory_record *, 
+											 char *, char *);
+extern int get_session_start(int *);
 
 /* joliet.c */
 #ifdef	UDF
 #   ifdef USE_ICONV
-extern	size_t	convert_to_unicode	__PR((unsigned char *buffer,
-			int size, char *source, struct unls_table *inls));
-extern	int	joliet_strlen		__PR((const char *string, struct unls_table *inls));
+extern	size_t	convert_to_unicode(unsigned char *buffer, int size, 
+												 char *source, struct unls_table *inls);
+extern	int	joliet_strlen(const char *string, struct unls_table *inls);
 #   else
-extern	void	convert_to_unicode	__PR((unsigned char *buffer,
-			int size, char *source, struct unls_table *inls));
-extern	int	joliet_strlen		__PR((const char *string));
+extern	void	convert_to_unicode(unsigned char *buffer, int size, 
+											 char *source, struct unls_table *inls);
+extern	int	joliet_strlen(const char *string);
 #   endif
 #endif
-extern unsigned char conv_charset __PR((unsigned char, struct unls_table *,
-				struct unls_table *));
-extern int joliet_sort_tree __PR((struct directory * node));
+extern unsigned char conv_charset(unsigned char, struct unls_table *,
+											 struct unls_table *);
+extern int joliet_sort_tree(struct directory * node);
 
 /* match.c */
-extern int matches __PR((char *));
-extern int add_match __PR((char *));
+extern int matches(char *);
+extern int add_match(char *);
 
 /* files.c */
-struct dirent	*readdir_add_files __PR((char **, char *, DIR *));
+struct dirent	*readdir_add_files(char **, char *, DIR *);
 
 /* name.c */
 
-extern void iso9660_check	__PR((struct iso_directory_record *idr, struct directory_entry *ndr));
-extern int iso9660_file_length __PR((const char *name,
-				struct directory_entry * sresult, int flag));
+extern void iso9660_check(struct iso_directory_record *idr, 
+								  struct directory_entry *ndr);
+extern int iso9660_file_length(const char *name, 
+										 struct directory_entry *sresult, int flag);
 
 /* various */
-extern int iso9660_date __PR((char *, time_t));
-extern void add_hash __PR((struct directory_entry *));
-extern struct file_hash *find_hash __PR((dev_t, ino_t));
+extern int iso9660_date(char *, time_t);
+extern void add_hash(struct directory_entry *);
+extern struct file_hash *find_hash(dev_t, ino_t);
 
-extern void flush_hash __PR((void));
-extern void add_directory_hash __PR((dev_t, ino_t));
-extern struct file_hash *find_directory_hash __PR((dev_t, ino_t));
-extern void flush_file_hash __PR((void));
-extern int delete_file_hash __PR((struct directory_entry *));
-extern struct directory_entry *find_file_hash __PR((char *));
-extern void add_file_hash __PR((struct directory_entry *));
+extern void flush_hash(void);
+extern void add_directory_hash(dev_t, ino_t);
+extern struct file_hash *find_directory_hash(dev_t, ino_t);
+extern void flush_file_hash(void);
+extern int delete_file_hash(struct directory_entry *);
+extern struct directory_entry *find_file_hash(char *);
+extern void add_file_hash(struct directory_entry *);
 
-extern int	generate_xa_rr_attributes __PR((char *, char *,
-				struct directory_entry *,
-				struct stat *, struct stat *,
-				int deep_flag));
-extern char	*generate_rr_extension_record __PR((char *id,
-				char *descriptor,
-				char *source, int *size));
+extern int	generate_xa_rr_attributes(char *, char *, struct directory_entry *,
+												  struct stat *, struct stat *, 
+												  int deep_flag);
+extern char	*generate_rr_extension_record(char *id, char *descriptor,
+														char *source, int *size);
 
-extern int	check_prev_session __PR((struct directory_entry **, int len,
-				struct directory_entry *,
-				struct stat *,
-				struct stat *,
-				struct directory_entry **));
+extern int	check_prev_session(struct directory_entry **, int len, 
+										 struct directory_entry *, struct stat *,
+										 struct stat *, struct directory_entry **);
 
-extern void	match_cl_re_entries __PR((void));
-extern void	finish_cl_pl_for_prev_session __PR((void));
-extern char	*find_rr_attribute __PR((unsigned char *pnt, int len, char *attr_type));
+extern void	match_cl_re_entries(void);
+extern void	finish_cl_pl_for_prev_session(void);
+extern char	*find_rr_attribute(unsigned char *pnt, int len, char *attr_type);
 
 #ifdef APPLE_HYB
 /* volume.c */
-extern int make_mac_volume __PR((struct directory * dpnt, int start_extent));
-extern int write_fork __PR((hfsfile * hfp, long tot));
+extern int make_mac_volume(struct directory * dpnt, int start_extent);
+extern int write_fork(hfsfile * hfp, long tot);
 
 /* apple.c */
 
-extern void del_hfs_info __PR((struct hfs_info *));
-extern int get_hfs_dir __PR((char *, char *, struct directory_entry *));
-extern int get_hfs_info __PR((char *, char *, struct directory_entry *));
-extern int get_hfs_rname __PR((char *, char *, char *));
-extern int hfs_exclude __PR((char *));
-extern void print_hfs_info __PR((struct directory_entry *));
-extern void hfs_init __PR((char *, unsigned short, unsigned int));
-extern void delete_rsrc_ent __PR((struct directory_entry *));
-extern void clean_hfs __PR((void));
-extern void perr __PR((char *));
-extern void set_root_info __PR((char *));
+extern void del_hfs_info(struct hfs_info *);
+extern int get_hfs_dir(char *, char *, struct directory_entry *);
+extern int get_hfs_info(char *, char *, struct directory_entry *);
+extern int get_hfs_rname(char *, char *, char *);
+extern int hfs_exclude(char *);
+extern void print_hfs_info(struct directory_entry *);
+extern void hfs_init(char *, unsigned short, unsigned int);
+extern void delete_rsrc_ent(struct directory_entry *);
+extern void clean_hfs(void);
+extern void perr(char *);
+extern void set_root_info(char *);
 
 /* desktop.c */
 
-extern int make_desktop __PR((hfsvol *, int));
+extern int make_desktop(hfsvol *, int);
 
 /* mac_label.c */
 
 #ifdef	_MAC_LABEL_H
 #ifdef PREP_BOOT
-extern void	gen_prepboot_label __PR((MacLabel * mac_label));
+extern void	gen_prepboot_label(MacLabel * mac_label);
 #endif
-extern int	gen_mac_label __PR((defer *));
+extern int	gen_mac_label(defer *);
 #endif
-extern int	autostart __PR((void));
+extern int	autostart(void);
 
 /* libfile */
 
-extern char	*get_magic_match __PR((const char *));
-extern void	clean_magic __PR((void));
+extern char	*get_magic_match(const char *);
+extern void	clean_magic(void);
 
 #endif	/* APPLE_HYB */
 
@@ -671,8 +664,8 @@
 extern struct eltorito_boot_entry_info *last_boot_entry;
 extern struct eltorito_boot_entry_info *current_boot_entry;
 
-extern char	*findgequal	__PR((char *));
-extern void	*e_malloc	__PR((size_t));
+extern char	*findgequal(char *);
+extern void	*e_malloc(size_t);
 
 /*
  * Note: always use these macros to avoid problems.

Modified: nonameyet/branches/cleanup/mkisofs/multi.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/multi.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/multi.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -69,67 +69,50 @@
 #define	TF_ACCESS 4
 #define	TF_ATTRIBUTES 8
 
-LOCAL	int	isonum_711	__PR((unsigned char *p));
-LOCAL	int	isonum_721	__PR((unsigned char *p));
-LOCAL	int	isonum_723	__PR((unsigned char *p));
-LOCAL	int	isonum_731	__PR((unsigned char *p));
+static	int	isonum_711(unsigned char *p);
+static	int	isonum_721(unsigned char *p);
+static	int	isonum_723(unsigned char *p);
+static	int	isonum_731(unsigned char *p);
 
-LOCAL	void	printasc	__PR((char *txt, unsigned char *p, int len));
-LOCAL	void	prbytes		__PR((char *txt, unsigned char *p, int len));
-unsigned char	*parse_xa	__PR((unsigned char *pnt, int *lenp,
-					struct directory_entry *dpnt));
-EXPORT	int	rr_flags	__PR((struct iso_directory_record *idr));
-LOCAL	int	parse_rrflags	__PR((Uchar *pnt, int len, int cont_flag));
-LOCAL	BOOL	find_rr		__PR((struct iso_directory_record *idr, Uchar **pntp, int *lenp));
-LOCAL	 int	parse_rr	__PR((unsigned char *pnt, int len,
-					struct directory_entry *dpnt));
-LOCAL	int	check_rr_dates	__PR((struct directory_entry *dpnt,
-					struct directory_entry *current,
-					struct stat *statbuf,
-					struct stat *lstatbuf));
-LOCAL	struct directory_entry **
-		read_merging_directory __PR((struct iso_directory_record *, int *));
-LOCAL	int	free_mdinfo	__PR((struct directory_entry **, int len));
-LOCAL	void	free_directory_entry __PR((struct directory_entry * dirp));
-LOCAL	void	merge_remaining_entries __PR((struct directory *,
-					struct directory_entry **, int));
+static	void	printasc(char *txt, unsigned char *p, int len);
+static	void	prbytes(char *txt, unsigned char *p, int len);
+unsigned char	*parse_xa(unsigned char *pnt, int *lenp,
+								 struct directory_entry *dpnt);
+int	rr_flags(struct iso_directory_record *idr);
+static	int	parse_rrflags(Uchar *pnt, int len, int cont_flag);
+static	BOOL	find_rr(struct iso_directory_record *idr, Uchar **pntp, 
+							  int *lenp);
+static	 int	parse_rr(unsigned char *pnt, int len, 
+								struct directory_entry *dpnt);
+static	int	check_rr_dates(struct directory_entry *dpnt,
+										struct directory_entry *current,
+										struct stat *statbuf,
+										struct stat *lstatbuf);
+static	struct directory_entry **
+		read_merging_directory(struct iso_directory_record *, int *);
+static	int	free_mdinfo(struct directory_entry **, int len);
+static	void	free_directory_entry(struct directory_entry * dirp);
+static	void	merge_remaining_entries(struct directory *,
+													struct directory_entry **, int);
 
-LOCAL	int	merge_old_directory_into_tree __PR((struct directory_entry *,
-							struct directory *));
-LOCAL	void	check_rr_relocation __PR((struct directory_entry * de));
+static	int	merge_old_directory_into_tree(struct directory_entry *,
+															struct directory *);
+static	void	check_rr_relocation(struct directory_entry *de);
 
-#ifdef	PROTOTYPES
-LOCAL int
+static int
 isonum_711(unsigned char *p)
-#else
-LOCAL int
-isonum_711(p)
-	unsigned char	*p;
-#endif
 {
 	return (*p & 0xff);
 }
 
-#ifdef	PROTOTYPES
-LOCAL int
+static int
 isonum_721(unsigned char *p)
-#else
-LOCAL int
-isonum_721(p)
-	unsigned char	*p;
-#endif
 {
 	return ((p[0] & 0xff) | ((p[1] & 0xff) << 8));
 }
 
-#ifdef	PROTOTYPES
-LOCAL int
+static int
 isonum_723(unsigned char *p)
-#else
-LOCAL int
-isonum_723(p)
-	unsigned char	*p;
-#endif
 {
 #if 0
 	if (p[0] != p[3] || p[1] != p[2]) {
@@ -144,14 +127,8 @@
 	return (isonum_721(p));
 }
 
-#ifdef	PROTOTYPES
-LOCAL int
+static int
 isonum_731(unsigned char *p)
-#else
-LOCAL int
-isonum_731(p)
-	unsigned char	*p;
-#endif
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8)
@@ -159,14 +136,8 @@
 		| ((p[3] & 0xff) << 24));
 }
 
-#ifdef	PROTOTYPES
 int
 isonum_733(unsigned char *p)
-#else
-int
-isonum_733(p)
-	unsigned char	*p;
-#endif
 {
 	return (isonum_731(p));
 }
@@ -188,16 +159,8 @@
  * Anyways, this allows the use of a scsi-generics type of interface on
  * Solaris.
  */
-#ifdef	PROTOTYPES
-LOCAL int
+static int
 readsecs(int startsecno, void *buffer, int sectorcount)
-#else
-LOCAL int
-readsecs(startsecno, buffer, sectorcount)
-	int		startsecno;
-	void		*buffer;
-	int		sectorcount;
-#endif
 {
 	int		f = fileno(in_image);
 
@@ -223,11 +186,8 @@
 
 #endif
 
-LOCAL void
-printasc(txt, p, len)
-	char		*txt;
-	unsigned char	*p;
-	int		len;
+static void
+printasc(char *txt, unsigned char *p, int len)
 {
 	int		i;
 
@@ -241,11 +201,8 @@
 	error("\n");
 }
 
-LOCAL void
-prbytes(txt, p, len)
-		char	*txt;
-	register Uchar	*p;
-	register int	len;
+static void
+prbytes(char *txt, register Uchar *p, register int len)
 {
 	error("%s", txt);
 	while (--len >= 0)
@@ -254,10 +211,7 @@
 }
 
 unsigned char *
-parse_xa(pnt, lenp, dpnt)
-	unsigned char	*pnt;
-	int		*lenp;
-	struct directory_entry *dpnt;
+parse_xa(unsigned char *pnt, int *lenp, struct directory_entry *dpnt)
 {
 	struct iso_xa_dir_record *xadp;
 	int		len = *lenp;
@@ -309,11 +263,8 @@
 	return (pnt);
 }
 
-LOCAL BOOL
-find_rr(idr, pntp, lenp)
-	struct iso_directory_record *idr;
-	Uchar		**pntp;
-	int		*lenp;
+static BOOL
+find_rr(struct iso_directory_record *idr, Uchar **pntp, int *lenp)
 {
 	struct iso_xa_dir_record *xadp;
 	int		len;
@@ -348,11 +299,8 @@
 	return (ret);
 }
 
-LOCAL int
-parse_rrflags(pnt, len, cont_flag)
-	Uchar	*pnt;
-	int	len;
-	int	cont_flag;
+static int
+parse_rrflags(Uchar *pnt, int len, int cont_flag)
 {
 	int	ncount;
 	int	cont_extent;
@@ -426,8 +374,7 @@
 }
 
 int
-rr_flags(idr)
-	struct iso_directory_record *idr;
+rr_flags(struct iso_directory_record *idr)
 {
 	int		len;
 	unsigned char	*pnt;
@@ -442,11 +389,8 @@
 /*
  * Parse the RR attributes so we can find the file name.
  */
-LOCAL int
-parse_rr(pnt, len, dpnt)
-	unsigned char	*pnt;
-	int		len;
-	struct directory_entry *dpnt;
+static int
+parse_rr(unsigned char *pnt, int len, struct directory_entry *dpnt)
 {
 	int		cont_extent;
 	int		cont_offset;
@@ -524,12 +468,11 @@
  * Returns 1 if the two files are identical
  * Returns 0 if the two files differ
  */
-LOCAL int
-check_rr_dates(dpnt, current, statbuf, lstatbuf)
-	struct directory_entry *dpnt;
-	struct directory_entry *current;
-	struct stat	*statbuf;
-	struct stat	*lstatbuf;
+static int
+check_rr_dates(struct directory_entry *dpnt, 
+					struct directory_entry *current, 
+					struct stat *statbuf, 
+					struct stat *lstatbuf)
 {
 	int		cont_extent;
 	int		cont_offset;
@@ -635,10 +578,8 @@
 	return (same_file);
 }
 
-LOCAL struct directory_entry **
-read_merging_directory(mrootp, nentp)
-	struct iso_directory_record *mrootp;
-	int		*nentp;
+static struct directory_entry **
+read_merging_directory(struct iso_directory_record *mrootp, int *nentp)
 {
 	unsigned char	*cpnt;
 	unsigned char	*cpnt1;
@@ -997,10 +938,8 @@
 /*
  * Free any associated data related to the structures.
  */
-LOCAL int
-free_mdinfo(ptr, len)
-	struct directory_entry **ptr;
-	int		len;
+static int
+free_mdinfo(struct directory_entry **ptr, int len)
 {
 	int		i;
 	struct directory_entry **p;
@@ -1022,9 +961,8 @@
 	return (0);
 }
 
-LOCAL void
-free_directory_entry(dirp)
-	struct directory_entry *dirp;
+static void
+free_directory_entry(struct directory_entry *dirp)
 {
 	if (dirp->name != NULL)
 		free(dirp->name);
@@ -1047,13 +985,11 @@
  * over so we don't bother to write it out to the new session.
  */
 int
-check_prev_session(ptr, len, curr_entry, statbuf, lstatbuf, odpnt)
-	struct directory_entry	**ptr;
-	int		len;
-	struct directory_entry *curr_entry;
-	struct stat	*statbuf;
-	struct stat	*lstatbuf;
-	struct directory_entry **odpnt;
+check_prev_session(struct directory_entry **ptr, int len, 
+						 struct directory_entry *curr_entry, 
+						 struct stat *statbuf, 
+						 struct stat *lstatbuf, 
+						 struct directory_entry **odpnt)
 {
 	int		i;
 	int		rr;
@@ -1151,8 +1087,7 @@
  * open_merge_image:  Open an existing image.
  */
 int
-open_merge_image(path)
-	char	*path;
+open_merge_image(char *path)
 {
 #ifndef	USE_SCG
 	in_image = fopen(path, "rb");
@@ -1187,8 +1122,7 @@
  * to the root directory for this image.
  */
 struct iso_directory_record *
-merge_isofs(path)
-	char	*path;
+merge_isofs(char *path)
 {
 	char		buffer[SECTOR_SIZE];
 	int		file_addr;
@@ -1250,11 +1184,9 @@
 	return (rootp);
 }
 
-LOCAL void
-merge_remaining_entries(this_dir, pnt, n_orig)
-	struct directory *this_dir;
-	struct directory_entry **pnt;
-	int		n_orig;
+static void
+merge_remaining_entries(struct directory *this_dir, 
+								struct directory_entry **pnt, int n_orig)
 {
 	int		i;
 	struct directory_entry *s_entry;
@@ -1379,10 +1311,9 @@
  * incorrectly pick it up and attempt to merge it back into the old
  * location.  FIXME(eric).
  */
-LOCAL int
-merge_old_directory_into_tree(dpnt, parent)
-	struct directory_entry	*dpnt;
-	struct directory *parent;
+static int
+merge_old_directory_into_tree(struct directory_entry *dpnt, 
+										struct directory *parent)
 {
 	struct directory_entry **contents = NULL;
 	int		i;
@@ -1499,8 +1430,7 @@
 char	*cdrecord_data = NULL;
 
 int
-get_session_start(file_addr)
-	int		*file_addr;
+get_session_start(int *file_addr)
 {
 	char		*pnt;
 
@@ -1570,11 +1500,10 @@
  * directory entries, so that we can determine how large each directory is.
  */
 int
-merge_previous_session(this_dir, mrootp, reloc_root, reloc_old_root)
-	struct directory *this_dir;
-	struct iso_directory_record *mrootp;
-	char *reloc_root;
-	char *reloc_old_root;
+merge_previous_session(struct directory *this_dir, 
+							  struct iso_directory_record *mrootp, 
+							  char *reloc_root, 
+							  char *reloc_old_root)
 {
 	struct directory_entry **orig_contents = NULL;
 	struct directory_entry *odpnt = NULL;
@@ -1818,9 +1747,8 @@
 static struct dir_extent_link	*cl_dirs = NULL;
 static struct dir_extent_link	*re_dirs = NULL;
 
-LOCAL void
-check_rr_relocation(de)
-	struct directory_entry *de;
+static void
+check_rr_relocation(struct directory_entry *de)
 {
 	unsigned char	sector[SECTOR_SIZE];
 	unsigned char	*pnt = de->rr_attributes;

Modified: nonameyet/branches/cleanup/mkisofs/name.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/name.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/name.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -48,15 +48,15 @@
 #include <schily.h>
 #include <ctype.h>
 
-void	iso9660_check		__PR((struct iso_directory_record *idr,	struct directory_entry *ndr));
-int	iso9660_file_length	__PR((const char *name,
-					struct directory_entry *sresult,
-					int dirflag));
+void	iso9660_check(struct iso_directory_record *idr,	
+						  struct directory_entry *ndr);
+int	iso9660_file_length(const char *name,
+								  struct directory_entry *sresult,
+								  int dirflag);
 
 void
-iso9660_check(idr, ndr)
-	struct iso_directory_record *idr;
-	struct directory_entry *ndr;
+iso9660_check(struct iso_directory_record *idr, 
+				  struct directory_entry *ndr)
 {
 	int	nlen;
 	char	schar;
@@ -114,10 +114,8 @@
  *		fix without going through the whole source.
  */
 int
-iso9660_file_length(name, sresult, dirflag)
-	const char	*name;			/* Not really const !!! */
-	struct directory_entry *sresult;
-	int		dirflag;
+iso9660_file_length(const char *name /* Not really const !!! */, 
+						  struct directory_entry *sresult, int dirflag)
 {
 	char		c;
 	char		*cp;

Modified: nonameyet/branches/cleanup/mkisofs/rock.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/rock.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/rock.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -70,22 +70,19 @@
 #define	TF_SIZE (5 + 3 * 7)
 #endif
 
-LOCAL	void	rstrncpy			__PR((char *t, char *f, int c,
+static	void	rstrncpy(char *t, char *f, int c,
 							struct unls_table *inls,
-							struct unls_table *onls));
-LOCAL	void	add_CE_entry			__PR((char *field, int line));
-LOCAL	int	gen_xa_attr			__PR((mode_t attr));
-LOCAL	void	gen_xa				__PR((struct stat *lstatbuf));
-EXPORT	int	generate_xa_rr_attributes	__PR((char *whole_name,
-							char *name,
-							struct directory_entry * s_entry,
-							struct stat * statbuf,
-							struct stat * lstatbuf,
-							int deep_opt));
-	char *	generate_rr_extension_record	__PR((char *id,
-							char *descriptor,
-							char *source,
-							int *size));
+							struct unls_table *onls);
+static	void	add_CE_entry(char *field, int line);
+static	int	gen_xa_attr(mode_t attr);
+static	void	gen_xa(struct stat *lstatbuf);
+int generate_xa_rr_attributes(char *whole_name, char *name,
+									 	struct directory_entry *s_entry,
+										struct stat *statbuf,
+										struct stat *lstatbuf,
+										int deep_opt);
+char *generate_rr_extension_record(char *id, char *descriptor, char *source,
+											  int *size);
 /*
  * If we need to store this number of bytes, make sure we
  * do not box ourselves in so that we do not have room for
@@ -99,22 +96,18 @@
 /*
  * Buffer to build RR attributes
  */
-LOCAL	Uchar	Rock[16384];
-LOCAL	Uchar	symlink_buff[PATH_MAX+1];
-LOCAL	int	ipnt = 0;	/* Current "write" offset in Rock[]	*/
-LOCAL	int	recstart = 0;	/* Start offset in Rock[] for this area	*/
-LOCAL	int	currlen = 0;	/* # of non RR bytes used in this area	*/
-LOCAL	int	mainrec = 0;	/* # of RR bytes use in main dir area	*/
-LOCAL	int	reclimit;	/* Max. # of bytes usable in this area	*/
+static	Uchar	Rock[16384];
+static	Uchar	symlink_buff[PATH_MAX+1];
+static	int	ipnt = 0;	/* Current "write" offset in Rock[]	*/
+static	int	recstart = 0;	/* Start offset in Rock[] for this area	*/
+static	int	currlen = 0;	/* # of non RR bytes used in this area	*/
+static	int	mainrec = 0;	/* # of RR bytes use in main dir area	*/
+static	int	reclimit;	/* Max. # of bytes usable in this area	*/
 
 /* if we are using converted filenames, we don't want the '/' character */
-LOCAL void
-rstrncpy(t, f, c, inls, onls)
-	char	*t;
-	char	*f;
-	int	c;
-	struct unls_table *inls;
-	struct unls_table *onls;
+static void
+rstrncpy(char *t, char *f, int c, struct unls_table *inls, 
+			struct unls_table *onls)
 {
 	while (c-- && *f) {
 		*t = conv_charset(*f, inls, onls);
@@ -126,10 +119,8 @@
 	}
 }
 
-LOCAL void
-add_CE_entry(field, line)
-	char	*field;
-	int	line;
+static void
+add_CE_entry(char *field, int line)
 {
 	if (MAYBE_ADD_CE_ENTRY(0)) {
 		errmsgno(EX_BAD,
@@ -161,14 +152,8 @@
 	reclimit = SECTOR_SIZE - 8;	/* Limit to one sector */
 }
 
-#ifdef	PROTOTYPES
-LOCAL int
+static int
 gen_xa_attr(mode_t attr)
-#else
-LOCAL int
-gen_xa_attr(attr)
-	mode_t	attr;
-#endif
 {
 	int	ret = 0;
 
@@ -195,9 +180,8 @@
 	return (ret);
 }
 
-LOCAL void
-gen_xa(lstatbuf)
-	struct stat	*lstatbuf;
+static void
+gen_xa(struct stat *lstatbuf)
 {
 		/*
 		 * Group ID
@@ -227,27 +211,12 @@
 
 }
 
-#ifdef PROTOTYPES
-EXPORT int
+int
 generate_xa_rr_attributes(char *whole_name, char *name,
-			struct directory_entry * s_entry,
-			struct stat * statbuf,
-			struct stat * lstatbuf,
-			int deep_opt)
-#else
-EXPORT int
-generate_xa_rr_attributes(whole_name, name,
-			s_entry,
-			statbuf,
-			lstatbuf,
-			deep_opt)
-	char		*whole_name;
-	char		*name;
-	struct directory_entry *s_entry;
-	struct stat	*statbuf,
-			*lstatbuf;
-	int		deep_opt;
-#endif
+								  struct directory_entry *s_entry,
+								  struct stat *statbuf,
+								  struct stat *lstatbuf,
+								  int deep_opt)
 {
 	int		flagpos;
 	int		flagval;
@@ -852,12 +821,9 @@
 /*
  * Guaranteed to  return a single sector with the relevant info
  */
-EXPORT char *
-generate_rr_extension_record(id, descriptor, source, size)
-	char	*id;
-	char	*descriptor;
-	char	*source;
-	int	*size;
+char *
+generate_rr_extension_record(char *id, char *descriptor, char *source, 
+									  int *size)
 {
 	int		lipnt = 0;
 	char		*pnt;

Modified: nonameyet/branches/cleanup/mkisofs/scsi.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/scsi.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/scsi.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -60,18 +60,15 @@
  */
 #define	BUF_SIZE	(62*1024)	/* Must be a multiple of 2048	   */
 
-LOCAL	SCSI	*scgp;
-LOCAL	long	bufsize;		/* The size of the transfer buffer */
+static	SCSI	*scgp;
+static	long	bufsize;		/* The size of the transfer buffer */
 
-EXPORT	int	readsecs	__PR((int startsecno, void *buffer, int sectorcount));
-EXPORT	int	scsidev_open	__PR((char *path));
-EXPORT	int	scsidev_close	__PR((void));
+int	readsecs(int startsecno, void *buffer, int sectorcount);
+int	scsidev_open(char *path);
+int	scsidev_close(void);
 
-EXPORT int
-readsecs(startsecno, buffer, sectorcount)
-	int	startsecno;
-	void	*buffer;
-	int	sectorcount;
+int
+readsecs(int startsecno, void *buffer, int sectorcount)
 {
 	int	f;
 	int	secsize;	/* The drive's SCSI sector size		*/
@@ -144,9 +141,8 @@
 	return (sectorcount * SECTOR_SIZE);
 }
 
-EXPORT int
-scsidev_open(path)
-	char	*path;
+int
+scsidev_open(char *path)
 {
 	char	errstr[80];
 	char	*buf;	/* ignored, bit OS/2 ASPI layer needs memory which */
@@ -190,7 +186,7 @@
 	return (1);
 }
 
-EXPORT int
+int
 scsidev_close()
 {
 	if (in_image == NULL) {

Modified: nonameyet/branches/cleanup/mkisofs/scsi.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/scsi.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/scsi.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -33,9 +33,9 @@
 #define	_SCSI_H
 
 #ifdef	USE_SCG
-extern int	readsecs	__PR((int startsecno, void *buffer, int sectorcount));
-extern int	scsidev_open	__PR((char *path));
-extern int	scsidev_close	__PR((void));
+extern int	readsecs(int startsecno, void *buffer, int sectorcount);
+extern int	scsidev_open(char *path);
+extern int	scsidev_close(void);
 #endif
 
 #endif	/* _SCSI_H */

Modified: nonameyet/branches/cleanup/mkisofs/stream.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/stream.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/stream.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -40,15 +40,15 @@
 #include "mkisofs.h"
 #include "iso9660.h"
 
-LOCAL int	size_str_file	__PR((int starting_extent));
-LOCAL int	size_str_dir	__PR((int starting_extent));
-LOCAL int	size_str_path	__PR((int starting_extent));
+static int	size_str_file(int starting_extent);
+static int	size_str_dir(int starting_extent);
+static int	size_str_path(int starting_extent);
 
-LOCAL int	gen_str_path	__PR((void));
+static int	gen_str_path(void);
 
-LOCAL int	write_str_file	__PR((FILE *outfile));
-LOCAL int	write_str_dir	__PR((FILE *outfile));
-LOCAL int	write_str_path	__PR((FILE *outfile));
+static int	write_str_file(FILE *outfile);
+static int	write_str_dir(FILE *outfile);
+static int	write_str_path(FILE *outfile);
 
 extern struct directory *root;
 extern unsigned int	session_start;
@@ -57,21 +57,20 @@
 extern time_t		begun;
 extern int		volume_sequence_number;
 
-LOCAL unsigned int	avail_extent;
-LOCAL unsigned int	stream_extent;
-LOCAL unsigned int	stream_size;
-LOCAL unsigned int	stream_pad;
-LOCAL char		*l_path;
-LOCAL char		*m_path;
-LOCAL struct iso_directory_record s_dir;
-LOCAL int		stream_finished = 0;
+static unsigned int	avail_extent;
+static unsigned int	stream_extent;
+static unsigned int	stream_size;
+static unsigned int	stream_pad;
+static char		*l_path;
+static char		*m_path;
+static struct iso_directory_record s_dir;
+static int		stream_finished = 0;
 
 /*
  * Compute the size of the file
  */
-LOCAL int
-size_str_file(starting_extent)
-	int	starting_extent;
+static int
+size_str_file(int starting_extent)
 {
 	int	n;
 extern	int	dopad;
@@ -98,9 +97,8 @@
 /*
  * The size of the directory record - one sector
  */
-LOCAL int
-size_str_dir(starting_extent)
-	int	starting_extent;
+static int
+size_str_dir(int starting_extent)
 {
 	root->extent = last_extent;
 	last_extent += 1;
@@ -110,9 +108,8 @@
 /*
  * The size of the path tables - two sectors
  */
-LOCAL int
-size_str_path(starting_extent)
-	int	starting_extent;
+static int
+size_str_path(int starting_extent)
 {
 	path_table[0] = starting_extent;
 	path_table[1] = 0;
@@ -125,7 +122,7 @@
 /*
  * Generate the path table data
  */
-LOCAL int
+static int
 gen_str_path()
 {
 	/*
@@ -149,9 +146,8 @@
 /*
  * Write the file content
  */
-LOCAL int
-write_str_file(outfile)
-	FILE	*outfile;
+static int
+write_str_file(FILE *outfile)
 {
 	unsigned int	idx = 0;
 	unsigned int	iso_blocks;
@@ -201,9 +197,8 @@
 /*
  * Generate and write the directory record data
  */
-LOCAL int
-write_str_dir(outfile)
-	FILE	*outfile;
+static int
+write_str_dir(FILE *outfile)
 {
 	int	to_write;
 	char	*buf;
@@ -258,9 +253,8 @@
 /*
  * Generate the path table data
  */
-LOCAL int
-write_str_path(outfile)
-	FILE	*outfile;
+static int
+write_str_path(FILE *outfile)
 {
 	jtwrite(l_path, SECTOR_SIZE, 1, 0, FALSE);
 	xfwrite(l_path, SECTOR_SIZE, 1, outfile, 0, FALSE);

Modified: nonameyet/branches/cleanup/mkisofs/tree.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/tree.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/tree.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -70,52 +70,47 @@
 #define	memmove(d, s, n)	bcopy((s), (d), (n))
 #endif
 
-LOCAL	Uchar	symlink_buff[PATH_MAX+1];
+static	Uchar	symlink_buff[PATH_MAX+1];
 
-LOCAL	char	*filetype		__PR((int t));
-LOCAL	char	*rstr			__PR((char *s1, char *s2));
-LOCAL	void	stat_fix		__PR((struct stat * st));
-EXPORT	int	stat_filter		__PR((char *path, struct stat *st));
-EXPORT	int	lstat_filter		__PR((char *path, struct stat *st));
-LOCAL	int	sort_n_finish		__PR((struct directory *this_dir));
-LOCAL	void	generate_reloc_directory __PR((void));
-LOCAL	void	attach_dot_entries	__PR((struct directory * dirnode,
-						struct stat * parent_stat));
-LOCAL	void	update_nlink		__PR((struct directory_entry *s_entry,
-						int value));
-LOCAL	void	increment_nlink		__PR((struct directory_entry *s_entry));
-EXPORT	char	*find_rr_attribute	__PR((unsigned char *pnt, int len,
-						char *attr_type));
-EXPORT	void	finish_cl_pl_entries	__PR((void));
-EXPORT	int	scan_directory_tree	__PR((struct directory *this_dir,
-						char *path,
-						struct directory_entry *de));
+static	char	*filetype(int t);
+static	char	*rstr(char *s1, char *s2);
+static	void	stat_fix(struct stat * st);
+int	stat_filter(char *path, struct stat *st);
+int	lstat_filter(char *path, struct stat *st);
+static	int	sort_n_finish(struct directory *this_dir);
+static	void	generate_reloc_directory(void);
+static	void	attach_dot_entries(struct directory *dirnode,
+											 struct stat *parent_stat);
+static	void	update_nlink(struct directory_entry *s_entry, int value);
+static	void	increment_nlink(struct directory_entry *s_entry);
+char	*find_rr_attribute(unsigned char *pnt, int len, char *attr_type);
+void	finish_cl_pl_entries(void);
+int	scan_directory_tree(struct directory *this_dir, char *path,
+								  struct directory_entry *de);
 #ifdef APPLE_HYB
-EXPORT	int	insert_file_entry	__PR((struct directory *this_dir,
-						char *whole_path,
-						char *short_name,
-						int have_rsrc));
+int	insert_file_entry(struct directory *this_dir,
+								char *whole_path,
+								char *short_name,
+								int have_rsrc);
 #else
-EXPORT	int	insert_file_entry	__PR((struct directory *this_dir,
-						char *whole_path,
-						char *short_name));
+int	insert_file_entry(struct directory *this_dir,
+								char *whole_path,
+								char *short_name);
 #endif
-EXPORT	void	generate_iso9660_directories __PR((struct directory *node,
-						FILE *outfile));
-EXPORT	struct directory *
-		find_or_create_directory __PR((struct directory *parent,
-						const char *path,
-						struct directory_entry *de,
-						int flag));
-LOCAL	void	delete_directory	__PR((struct directory * parent,
-						struct directory * child));
-EXPORT	int	sort_tree		__PR((struct directory *node));
-EXPORT	void	dump_tree		__PR((struct directory *node));
-EXPORT	void	update_nlink_field	__PR((struct directory *node));
-EXPORT	struct directory_entry *
-		search_tree_file	__PR((struct directory *node,
-						char *filename));
-EXPORT	void	init_fstatbuf		__PR((void));
+void	generate_iso9660_directories(struct directory *node,
+											  FILE *outfile);
+struct directory *find_or_create_directory(struct directory *parent,
+														 const char *path,
+														 struct directory_entry *de,
+														 int flag);
+static	void	delete_directory(struct directory *parent,
+										  struct directory *child);
+int	sort_tree(struct directory *node);
+void	dump_tree(struct directory *node);
+void	update_nlink_field(struct directory *node);
+struct directory_entry *search_tree_file(struct directory *node,
+													  char *filename);
+void	init_fstatbuf(void);
 
 extern int	verbose;
 struct stat	fstatbuf;		/* We use this for the artificial */
@@ -123,9 +118,8 @@
 struct stat	root_statbuf;		/* Stat buffer for root directory */
 struct directory *reloc_dir;
 
-LOCAL char *
-filetype(t)
-	int	t;
+static char *
+filetype(int t)
 {
 	static	char	unkn[32];
 
@@ -174,10 +168,8 @@
 /*
  * Check if s1 ends in strings s2
  */
-LOCAL char *
-rstr(s1, s2)
-	char	*s1;
-	char	*s2;
+static char *
+rstr(char *s1, char *s2)
 {
 	int	l1;
 	int	l2;
@@ -192,9 +184,8 @@
 	return ((char *) NULL);
 }
 
-LOCAL void
-stat_fix(st)
-	struct stat	*st;
+static void
+stat_fix(struct stat *st)
 {
 	int adjust_modes = 0;
 
@@ -241,10 +232,8 @@
 	}
 }
 
-EXPORT int
-stat_filter(path, st)
-	char		*path;
-	struct stat	*st;
+int
+stat_filter(char *path, struct stat *st)
 {
 	int	result = stat(path, st);
 
@@ -253,10 +242,8 @@
 	return (result);
 }
 
-EXPORT int
-lstat_filter(path, st)
-	char		*path;
-	struct stat	*st;
+int
+lstat_filter(char *path, struct stat *st)
 {
 	int	result = lstat(path, st);
 
@@ -265,9 +252,8 @@
 	return (result);
 }
 
-LOCAL int
-sort_n_finish(this_dir)
-	struct directory	*this_dir;
+static int
+sort_n_finish(struct directory *this_dir)
 {
 	struct directory_entry *s_entry;
 	struct directory_entry *s_entry1;
@@ -794,7 +780,7 @@
 	return (status);
 }
 
-LOCAL void
+static void
 generate_reloc_directory()
 {
 	time_t		current_time;
@@ -871,10 +857,9 @@
  * Notes:		Only used for artificial directories that
  *			we are creating.
  */
-LOCAL void
-attach_dot_entries(dirnode, parent_stat)
-	struct directory	*dirnode;
-	struct stat		*parent_stat;
+static void
+attach_dot_entries(struct directory *dirnode, 
+						 struct stat *parent_stat)
 {
 	struct directory_entry *s_entry;
 	struct directory_entry *orig_contents;
@@ -967,10 +952,8 @@
 	}
 }
 
-LOCAL void
-update_nlink(s_entry, value)
-	struct directory_entry	*s_entry;
-	int			value;
+static void
+update_nlink(struct directory_entry *s_entry, int value)
 {
 	unsigned char	*pnt;
 	int		len;
@@ -999,9 +982,8 @@
 	}
 }
 
-LOCAL void
-increment_nlink(s_entry)
-	struct directory_entry	*s_entry;
+static void
+increment_nlink(struct directory_entry *s_entry)
 {
 	unsigned char	*pnt;
 	int		len,
@@ -1032,11 +1014,8 @@
 	}
 }
 
-EXPORT char *
-find_rr_attribute(pnt, len, attr_type)
-	unsigned char	*pnt;
-	int		len;
-	char		*attr_type;
+char *
+find_rr_attribute(unsigned char *pnt, int len, char *attr_type)
 {
 	pnt = parse_xa(pnt, &len, 0);
 	while (len >= 4) {
@@ -1061,7 +1040,7 @@
 	return (NULL);
 }
 
-EXPORT void
+void
 finish_cl_pl_entries()
 {
 	struct directory_entry	*s_entry;
@@ -1158,11 +1137,9 @@
  *
  * Notes:
  */
-EXPORT int
-scan_directory_tree(this_dir, path, de)
-	struct directory	*this_dir;
-	char			*path;
-	struct directory_entry	*de;
+int
+scan_directory_tree(struct directory *this_dir, char *path, 
+						  struct directory_entry *de)
 {
 	DIR		*current_dir;
 	char		whole_path[PATH_MAX];
@@ -1404,18 +1381,13 @@
  * trees before we return.
  */
 #ifdef APPLE_HYB
-EXPORT int
-insert_file_entry(this_dir, whole_path, short_name, have_rsrc)
-	struct directory	*this_dir;
-	char			*whole_path;
-	char			*short_name;
-	int			have_rsrc;
+int
+insert_file_entry(struct directory *this_dir, char *whole_path, 
+						char *short_name, int have_rsrc)
 #else
-EXPORT int
-insert_file_entry(this_dir, whole_path, short_name)
-	struct directory	*this_dir;
-	char			*whole_path;
-	char			*short_name;
+int
+insert_file_entry(struct directory *this_dir, char *whole_path, 
+						char *short_name)
 #endif	/* APPLE_HYB */
 {
 	struct stat	statbuf,
@@ -2232,10 +2204,8 @@
 }
 
 
-EXPORT void
-generate_iso9660_directories(node, outfile)
-	struct directory	*node;
-	FILE			*outfile;
+void
+generate_iso9660_directories(struct directory *node, FILE *outfile)
 {
 	struct directory *dpnt;
 
@@ -2258,12 +2228,9 @@
  *
  * Arguments:	parent & de are never NULL at the same time.
  */
-EXPORT struct directory *
-find_or_create_directory(parent, path, de, flag)
-	struct directory	*parent;
-	const char		*path;
-	struct directory_entry	*de;
-	int			flag;
+struct directory *
+find_or_create_directory(struct directory *parent, const char *path, 
+								 struct directory_entry *de, int flag)
 {
 	struct directory *dpnt;
 	struct directory_entry *orig_de;
@@ -2473,7 +2440,7 @@
  *
  * Arguments:
  */
-LOCAL void
+static void
 delete_directory(parent, child)
 	struct directory	*parent;
 	struct directory	*child;
@@ -2523,9 +2490,8 @@
 	free(child);
 }
 
-EXPORT int
-sort_tree(node)
-	struct directory	*node;
+int
+sort_tree(struct directory *node)
 {
 	struct directory *dpnt;
 	int		ret = 0;
@@ -2544,9 +2510,8 @@
 	return (ret);
 }
 
-EXPORT void
-dump_tree(node)
-	struct directory *node;
+void
+dump_tree(struct directory *node)
 {
 	struct directory *dpnt;
 
@@ -2561,9 +2526,8 @@
 	}
 }
 
-EXPORT void
-update_nlink_field(node)
-	struct directory *node;
+void
+update_nlink_field(struct directory *node)
 {
 	struct directory *dpnt;
 	struct directory *xpnt;
@@ -2619,10 +2583,8 @@
  * recursively walks down path in filename until it finds the
  * directory entry for the desired file
  */
-EXPORT struct directory_entry *
-search_tree_file(node, filename)
-	struct directory *node;
-	char		*filename;
+struct directory_entry *
+search_tree_file(struct directory *node, char *filename)
 {
 	struct directory_entry *depnt;
 	struct directory *dpnt;
@@ -2698,7 +2660,7 @@
 #endif
 }
 
-EXPORT void
+void
 init_fstatbuf()
 {
 	time_t	current_time;

Modified: nonameyet/branches/cleanup/mkisofs/udf.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/udf.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/udf.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -125,15 +125,11 @@
 
 /**************** SIZE ****************/
 
-static int set_file_ident_desc __PR((unsigned char *, unsigned, char *, int, unsigned, unsigned));
+static int set_file_ident_desc(unsigned char *, unsigned, char *, int, 
+										 unsigned, unsigned);
 
 static unsigned
-#ifdef PROTOTYPES
 directory_size(struct directory *dpnt)
-#else
-directory_size(dpnt)
-	struct directory	*dpnt;
-#endif
 {
 	unsigned size_in_bytes;
 	struct directory_entry *de;
@@ -156,12 +152,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 assign_udf_directory_addresses(struct directory *dpnt)
-#else
-assign_udf_directory_addresses(dpnt)
-	struct directory	*dpnt;
-#endif
 {
 	if (!(dpnt->dir_flags & INHIBIT_JOLIET_ENTRY)) {
 		dpnt->self->udf_file_entry_sector = last_extent;
@@ -176,12 +167,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 assign_udf_file_entry_addresses(struct directory *dpnt)
-#else
-assign_udf_file_entry_addresses(dpnt)
-	struct directory	*dpnt;
-#endif
 {
 	if (!(dpnt->dir_flags & INHIBIT_JOLIET_ENTRY)) {
 		struct directory_entry *de;
@@ -203,24 +189,14 @@
 /****************************/
 
 static int
-#ifdef PROTOTYPES
 udf_vol_recognition_area_size(int starting_extent)
-#else
-udf_vol_recognition_area_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	last_extent = starting_extent+3;
 	return (0);
 }
 
 static int
-#ifdef PROTOTYPES
 udf_main_seq_size(int starting_extent)
-#else
-udf_main_seq_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	lba_main_seq = starting_extent;
 	last_extent = starting_extent + UDF_MAIN_SEQ_LENGTH;
@@ -228,12 +204,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_main_seq_copy_size(int starting_extent)
-#else
-udf_main_seq_copy_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	lba_main_seq_copy = starting_extent;
 	last_extent = starting_extent + UDF_MAIN_SEQ_LENGTH;
@@ -241,12 +212,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_integ_seq_size(int starting_extent)
-#else
-udf_integ_seq_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	lba_integ_seq = starting_extent;
 	last_extent = starting_extent + UDF_INTEG_SEQ_LENGTH;
@@ -254,12 +220,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_end_anchor_vol_desc_size(int starting_extent)
-#else
-udf_end_anchor_vol_desc_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	lba_end_anchor_vol_desc = starting_extent;
 	last_extent = starting_extent+1;
@@ -267,12 +228,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_file_set_desc_size(int starting_extent)
-#else
-udf_file_set_desc_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	lba_udf_partition_start = starting_extent;
 	last_extent = starting_extent+2;
@@ -280,12 +236,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_dirtree_size(int starting_extent)
-#else
-udf_dirtree_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	num_udf_directories = 0;
 	assign_udf_directory_addresses(root);
@@ -293,12 +244,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_file_entries_size(int starting_extent)
-#else
-udf_file_entries_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	num_udf_files = 0;
 	assign_udf_file_entry_addresses(root);
@@ -307,12 +253,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_pad_to_sector_32_size(int starting_extent)
-#else
-udf_pad_to_sector_32_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	if (last_extent < session_start+32)
 		last_extent = session_start+32;
@@ -320,12 +261,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_pad_to_sector_256_size(int starting_extent)
-#else
-udf_pad_to_sector_256_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	if (last_extent < session_start+256)
 		last_extent = session_start+256;
@@ -333,12 +269,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_padend_avdp_size(int starting_extent)
-#else
-udf_padend_avdp_size(starting_extent)
-	int	starting_extent;
-#endif
 {
 	lba_end_anchor_vol_desc = starting_extent;
 
@@ -349,18 +280,12 @@
 	return (0);
 }
 
-extern int oneblock_size __PR((int));
+extern int oneblock_size(int);
 
 /**************** WRITE ****************/
 
 static unsigned
-#ifdef PROTOTYPES
 crc_ccitt(unsigned char *buf, unsigned len)
-#else
-crc_ccitt(buf, len)
-	unsigned char	*buf;
-	unsigned	len;
-#endif
 {
 	const unsigned poly = 0x11021;
 	static unsigned short lookup[256];
@@ -392,26 +317,14 @@
 #define	set8(dst, src)	do { *(dst) = (src); } while (0)
 
 static void
-#ifdef PROTOTYPES
 set16(udf_Uint16 *dst, unsigned int src)
-#else
-set16(dst, src)
-	udf_Uint16	*dst;
-	unsigned int	src;
-#endif
 {
 	dst->l = (char)(src);
 	dst->h = (char)(src>>8);
 }
 
 static void
-#ifdef PROTOTYPES
 set32(udf_Uint32 *dst, unsigned src)
-#else
-set32(dst, src)
-	udf_Uint32	*dst;
-	unsigned	src;
-#endif
 {
 	dst->l  = (char)(src);
 	dst->ml = (char)(src>>8);
@@ -420,13 +333,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set64(udf_Uint64 *dst, unsigned src)
-#else
-set64(dst, src)
-	udf_Uint64	*dst;
-	unsigned	src;
-#endif
 {
 	set32(&dst->l, src);
 	/*
@@ -440,14 +347,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 set_ostaunicode(unsigned char *dst, int dst_size, char *src)
-#else
-set_ostaunicode(dst, dst_size, src)
-	unsigned char	*dst;
-	int		dst_size;
-	char		*src;
-#endif
 {
 	unsigned char buf[1024];
 	int i;
@@ -480,65 +380,33 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_extent(udf_extent_ad *ext, unsigned lba, unsigned length_bytes)
-#else
-set_extent(ext, lba, length_bytes)
-	udf_extent_ad	*ext;
-	unsigned	lba;
-	unsigned	length_bytes;
-#endif
 {
 	set32(&ext->extent_length, length_bytes);
 	set32(&ext->extent_location, lba);
 }
 
 static void
-#ifdef PROTOTYPES
 set_dstring(udf_dstring *dst, char *src, int n)
-#else
-set_dstring(dst, src, n)
-	udf_dstring	*dst;
-	char		*src;
-	int		n;
-#endif
 {
 	dst[n-1] = set_ostaunicode((Uchar *)dst, n-1, src);
 }
 
 static void
-#ifdef PROTOTYPES
 set_charspec(udf_charspec *dst)
-#else
-set_charspec(dst)
-	udf_charspec	*dst;
-#endif
 {
 	/*set8(&dst->character_set_type, 0);*/
 	memcpy(dst->character_set_info, "OSTA Compressed Unicode", 23);
 }
 
 static void
-#ifdef PROTOTYPES
 set_impl_ident(udf_EntityID *ent)
-#else
-set_impl_ident(ent)
-	udf_EntityID	*ent;
-#endif
 {
 	strcpy((char *)ent->ident, "*mkisofs");
 }
 
 static void
-#ifdef PROTOTYPES
 set_tag(udf_tag *t, unsigned tid, unsigned lba, int crc_length)
-#else
-set_tag(t, tid, lba, crc_length)
-	udf_tag	*t;
-	unsigned	tid;
-	unsigned	lba;
-	int		crc_length;
-#endif
 {
 	unsigned char checksum;
 	int i;
@@ -556,13 +424,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_timestamp_from_iso_date(udf_timestamp *ts, const char *iso_date_raw)
-#else
-set_timestamp_from_iso_date(ts, iso_date_raw)
-	udf_timestamp	*ts;
-	const char	*iso_date_raw;
-#endif
 {
 	struct {
 		unsigned char years_since_1900;
@@ -585,13 +447,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_timestamp_from_time_t(udf_timestamp *ts, time_t t)
-#else
-set_timestamp_from_time_t(ts, t)
-	udf_timestamp	*ts;
-	time_t		t;
-#endif
 {
 	char iso_date[7];
 	iso9660_date(iso_date, t);
@@ -600,13 +456,7 @@
 
 
 static void
-#ifdef PROTOTYPES
 set_anchor_volume_desc_pointer(unsigned char *buf, unsigned lba)
-#else
-set_anchor_volume_desc_pointer(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_anchor_volume_desc_ptr *avdp = (udf_anchor_volume_desc_ptr *)buf;
 	set_extent(&avdp->main_volume_desc_seq_extent,
@@ -617,13 +467,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_primary_vol_desc(unsigned char *buf, unsigned lba)
-#else
-set_primary_vol_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	char temp[17];
 
@@ -651,13 +495,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_impl_use_vol_desc(unsigned char *buf, unsigned lba)
-#else
-set_impl_use_vol_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_impl_use_volume_desc *iuvd = (udf_impl_use_volume_desc *)buf;
 	set32(&iuvd->volume_desc_seq_number, 1);
@@ -675,13 +513,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_partition_desc(unsigned char *buf, unsigned lba)
-#else
-set_partition_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_partition_desc *pd = (udf_partition_desc *)buf;
 	set32(&pd->volume_desc_seq_number, 2);
@@ -698,25 +530,14 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_domain_ident(udf_EntityID *ent)
-#else
-set_domain_ident(ent)
-	udf_EntityID	*ent;
-#endif
 {
 	strcpy((char *)ent->ident, "*OSTA UDF Compliant");
 	memcpy(ent->ident_suffix, "\002\001\003", 3);
 }
 
 static void
-#ifdef PROTOTYPES
 set_logical_vol_desc(unsigned char *buf, unsigned lba)
-#else
-set_logical_vol_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_logical_volume_desc *lvd = (udf_logical_volume_desc *)buf;
 	set32(&lvd->volume_desc_seq_number, 3);
@@ -742,13 +563,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_unallocated_space_desc(unsigned char *buf, unsigned lba)
-#else
-set_unallocated_space_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_unallocated_space_desc *usd = (udf_unallocated_space_desc *)buf;
 	set32(&usd->volume_desc_seq_number, 4);
@@ -757,26 +572,14 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_terminating_desc(unsigned char *buf, unsigned lba)
-#else
-set_terminating_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_terminating_desc *td = (udf_terminating_desc *)buf;
 	set_tag(&td->desc_tag, UDF_TAGID_TERMINATING_DESC, lba, 512);
 }
 
 static void
-#ifdef PROTOTYPES
 set_logical_vol_integrity_desc(unsigned char *buf, unsigned lba)
-#else
-set_logical_vol_integrity_desc(buf, lba)
-	unsigned char	*buf;
-	unsigned	lba;
-#endif
 {
 	udf_logical_volume_integrity_desc *lvid =
 				(udf_logical_volume_integrity_desc *)buf;
@@ -802,13 +605,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 set_file_set_desc(unsigned char *buf, unsigned rba)
-#else
-set_file_set_desc(buf, rba)
-	unsigned char	*buf;
-	unsigned	rba;
-#endif
 {
 	udf_file_set_desc *fsd = (udf_file_set_desc *)buf;
 
@@ -836,17 +633,9 @@
 }
 
 static int
-#ifdef PROTOTYPES
-set_file_ident_desc(unsigned char *buf, unsigned rba, char *name, int is_directory, unsigned file_entry_rba, unsigned unique_id)
-#else
-set_file_ident_desc(buf, rba, name, is_directory, file_entry_rba, unique_id)
-	unsigned char	*buf;
-	unsigned	rba;
-	char		*name;
-	int		is_directory;
-	unsigned	file_entry_rba;
-	unsigned	unique_id;
-#endif
+set_file_ident_desc(unsigned char *buf, unsigned rba, char *name, 
+						  int is_directory, unsigned file_entry_rba, 
+						  unsigned unique_id)
 {
 	udf_file_ident_desc *fid = (udf_file_ident_desc *)buf;
 	int length_of_file_ident, length, padded_length;
@@ -876,26 +665,9 @@
 }
 
 static void
-#ifdef PROTOTYPES
-set_file_entry(unsigned char *buf,
-	unsigned rba,
-	unsigned file_rba,
-	unsigned length,
-	const char *iso_date,
-	int is_directory,
-	unsigned link_count,
-	unsigned unique_id)
-#else
-set_file_entry(buf, rba, file_rba, length, iso_date, is_directory, link_count, unique_id)
-	unsigned char	*buf;
-	unsigned	rba;
-	unsigned	file_rba;
-	unsigned	length;
-	const char	*iso_date;
-	int		is_directory;
-	unsigned	link_count;
-	unsigned	unique_id;
-#endif
+set_file_entry(unsigned char *buf, unsigned rba, unsigned file_rba,
+					unsigned length, const char *iso_date, int is_directory,
+					unsigned link_count, unsigned unique_id)
 {
 	udf_short_ad	*allocation_desc;
 	unsigned	chunk;
@@ -999,12 +771,7 @@
 }
 
 static unsigned
-#ifdef PROTOTYPES
 directory_link_count(struct directory *dpnt)
-#else
-directory_link_count(dpnt)
-	struct directory	*dpnt;
-#endif
 {
 	/*
 	 * The link count is equal to 1 (for the parent) plus the
@@ -1031,13 +798,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 write_one_udf_directory(struct directory *dpnt, FILE *outfile)
-#else
-write_one_udf_directory(dpnt, outfile)
-	struct directory	*dpnt;
-	FILE			*outfile;
-#endif
 {
 	unsigned size_in_bytes, padded_size_in_bytes;
 	struct directory_entry *de;
@@ -1136,13 +897,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 write_udf_directories(struct directory *dpnt, FILE *outfile)
-#else
-write_udf_directories(dpnt, outfile)
-	struct directory	*dpnt;
-	FILE			*outfile;
-#endif
 {
 	if (!(dpnt->dir_flags & INHIBIT_JOLIET_ENTRY)) {
 		write_one_udf_directory(dpnt, outfile);
@@ -1155,13 +910,7 @@
 }
 
 static void
-#ifdef PROTOTYPES
 write_udf_file_entries(struct directory *dpnt, FILE *outfile)
-#else
-write_udf_file_entries(dpnt, outfile)
-	struct directory	*dpnt;
-	FILE			*outfile;
-#endif
 {
 	Uchar buf[SECTOR_SIZE];
 
@@ -1198,12 +947,7 @@
 /****************************/
 
 static int
-#ifdef PROTOTYPES
 udf_vol_recognition_area_write(FILE *out)
-#else
-udf_vol_recognition_area_write(out)
-	FILE	*out;
-#endif
 {
 	static const char *identifiers[3] = { "BEA01", "NSR02", "TEA01" };
 	int i;
@@ -1223,12 +967,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_main_seq_write(FILE *out)
-#else
-udf_main_seq_write(out)
-	FILE	*out;
-#endif
 {
 	Uchar buf[SECTOR_SIZE];
 	int i;
@@ -1281,12 +1020,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_integ_seq_write(FILE *out)
-#else
-udf_integ_seq_write(out)
-	FILE	*out;
-#endif
 {
 	Uchar buf[SECTOR_SIZE*UDF_INTEG_SEQ_LENGTH];
 
@@ -1302,12 +1036,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_anchor_vol_desc_write(FILE *out)
-#else
-udf_anchor_vol_desc_write(out)
-	FILE	*out;
-#endif
 {
 	Uchar buf[SECTOR_SIZE];
 
@@ -1319,12 +1048,7 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_file_set_desc_write(FILE *out)
-#else
-udf_file_set_desc_write(out)
-	FILE	*out;
-#endif
 {
 	Uchar buf[SECTOR_SIZE*2];
 
@@ -1342,37 +1066,21 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_dirtree_write(FILE *out)
-#else
-udf_dirtree_write(out)
-	FILE	*out;
-#endif
 {
 	write_udf_directories(root, out);
 	return (0);
 }
 
 static int
-#ifdef PROTOTYPES
 udf_file_entries_write(FILE *out)
-#else
-udf_file_entries_write(out)
-	FILE	*out;
-#endif
 {
 	write_udf_file_entries(root, out);
 	return (0);
 }
 
 static int
-#ifdef PROTOTYPES
 pad_to(unsigned last_extent_to_write, FILE *out)
-#else
-pad_to(last_extent_to_write, out)
-	unsigned	last_extent_to_write;
-	FILE		*out;
-#endif
 {
 	char buf[SECTOR_SIZE];
 	memset(buf, 0, sizeof (buf));
@@ -1385,34 +1093,19 @@
 }
 
 static int
-#ifdef PROTOTYPES
 udf_pad_to_sector_32_write(FILE *out)
-#else
-udf_pad_to_sector_32_write(out)
-	FILE	*out;
-#endif
 {
 	return (pad_to(session_start+32, out));
 }
 
 static int
-#ifdef PROTOTYPES
 udf_pad_to_sector_256_write(FILE *out)
-#else
-udf_pad_to_sector_256_write(out)
-	FILE	*out;
-#endif
 {
 	return (pad_to(session_start+256, out));
 }
 
 static int
-#ifdef PROTOTYPES
 udf_padend_avdp_write(FILE *out)
-#else
-udf_padend_avdp_write(out)
-	FILE	*out;
-#endif
 {
 	Uchar buf[SECTOR_SIZE];
 	unsigned last_extent_to_write = (last_extent_written+31) & ~15;
@@ -1474,14 +1167,7 @@
  * weight. This obviously needs to be tested.
  */
 int
-#ifdef PROTOTYPES
 assign_dvd_weights(char *name, struct directory *this_dir, int val)
-#else
-assign_dvd_weights(name, this_dir, val)
-	char			*name;
-	struct directory	*this_dir;
-	int			val;
-#endif
 {
 	int ts_number;
 	int segment;

Modified: nonameyet/branches/cleanup/mkisofs/udf.h
===================================================================
--- nonameyet/branches/cleanup/mkisofs/udf.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/udf.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -48,6 +48,6 @@
 extern struct output_fragment udf_pad_to_sector_256_frag;
 extern struct output_fragment udf_padend_avdp_frag;
 
-int assign_dvd_weights __PR((char *name, struct directory *this_dir, int val));
+int assign_dvd_weights(char *name, struct directory *this_dir, int val);
 
 #endif	/* _UDF_H */

Modified: nonameyet/branches/cleanup/mkisofs/volume.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/volume.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/volume.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -54,22 +54,21 @@
 
 #define	HFS_MIN_SIZE	1600	/* 800k == 1600 HFS blocks */
 
-LOCAL hfsvol  *vol_save = 0;	/* used to "destroy" an HFS volume */
+static hfsvol  *vol_save = 0;	/* used to "destroy" an HFS volume */
 
-LOCAL	int	AlcSiz		__PR((Ulong));
-LOCAL	int	XClpSiz		__PR((Ulong));
-LOCAL	int	get_vol_size	__PR((int));
-EXPORT	int	write_fork	__PR((hfsfile * hfp, long tot));
-EXPORT	int	make_mac_volume	__PR((struct directory *, int));
-LOCAL	int	copy_to_mac_vol	__PR((hfsvol *, struct directory *));
-LOCAL void	set_dir_info	__PR((hfsvol *, struct directory *));
+static	int	AlcSiz(Ulong);
+static	int	XClpSiz(Ulong);
+static	int	get_vol_size(int);
+int	write_fork(hfsfile * hfp, long tot);
+int	make_mac_volume(struct directory *, int);
+static	int	copy_to_mac_vol(hfsvol *, struct directory *);
+static void	set_dir_info(hfsvol *, struct directory *);
 
 /*
  *	AlcSiz: find allocation size for given volume size
  */
-LOCAL int
-AlcSiz(vlen)
-	Ulong	vlen;
+static int
+AlcSiz(Ulong vlen)
 {
 	int	lpa,
 		drAlBlkSiz;
@@ -90,9 +89,8 @@
 /*
  *	XClpSiz: find the default size of the catalog/extent file
  */
-LOCAL int
-XClpSiz(vlen)
-	Ulong	vlen;
+static int
+XClpSiz(Ulong vlen)
 {
 	int	olpa,
 		lpa,
@@ -134,9 +132,8 @@
 /*
  *	get_vol_size: get the size of the volume including the extent/catalog
  */
-LOCAL int
-get_vol_size(vblen)
-	int	vblen;
+static int
+get_vol_size(int vblen)
 {
 	int	drXTClpSiz;
 	int	drAlBlkSiz;
@@ -169,10 +166,8 @@
  *	but no data is actually written (it's trapped deep down in
  *	libhfs).
  */
-EXPORT int
-write_fork(hfp, tot)
-	hfsfile	*hfp;
-	long	tot;
+int
+write_fork(hfsfile *hfp, long tot)
 {
 	char		blk[HFS_BLOCKSZ];
 	unsigned short	start;
@@ -212,10 +207,8 @@
  *	size, so we may have to update the ISO structures to add in any
  *	padding.
  */
-EXPORT int
-make_mac_volume(dpnt, start_extent)
-	struct directory	*dpnt;
-	int			start_extent;
+int
+make_mac_volume(struct directory  *dpnt, int start_extent)
 {
 	char	vol_name[HFS_MAX_VLEN + 1];	/* Mac volume name */
 	hfsvol	*vol;			/* Mac volume */
@@ -349,10 +342,8 @@
  *	volume. The caller routine needs to do a hfs_chdir before calling this
  *	routine.
  */
-LOCAL int
-copy_to_mac_vol(vol, node)
-	hfsvol		*vol;
-	struct directory *node;
+static int
+copy_to_mac_vol(hfsvol *vol, struct directory *node)
 {
 	struct directory_entry	*s_entry;	/* ISO directory entry */
 	struct directory_entry	*s_entry1;	/* tmp ISO directory entry */
@@ -686,10 +677,8 @@
 
 #define	ICON	"Icon"
 
-LOCAL void
-set_dir_info(vol, de)
-	hfsvol			*vol;
-	struct directory	*de;
+static void
+set_dir_info(hfsvol *vol, struct directory *de)
 {
 	hfsdirent	*ent = de->hfs_ent;
 	hfsdirent	ent1;

Modified: nonameyet/branches/cleanup/mkisofs/write.c
===================================================================
--- nonameyet/branches/cleanup/mkisofs/write.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/mkisofs/write.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -67,99 +67,96 @@
 
 /* Counters for statistics */
 
-LOCAL int	table_size = 0;
-LOCAL int	total_dir_size = 0;
-LOCAL int	rockridge_size = 0;
-LOCAL struct directory **pathlist;
-LOCAL int	next_path_index = 1;
-LOCAL int	sort_goof;
+static int	table_size = 0;
+static int	total_dir_size = 0;
+static int	rockridge_size = 0;
+static struct directory **pathlist;
+static int	next_path_index = 1;
+static int	sort_goof;
 
-LOCAL int	is_rr_dir = 0;
+static int	is_rr_dir = 0;
 
 struct output_fragment *out_tail;
 struct output_fragment *out_list;
 
 struct iso_primary_descriptor vol_desc;
 
-EXPORT	void	set_721		__PR((char *pnt, unsigned int i));
-EXPORT	void	set_722		__PR((char *pnt, unsigned int i));
-EXPORT	void	set_723		__PR((char *pnt, unsigned int i));
-EXPORT	void	set_731		__PR((char *pnt, unsigned int i));
-EXPORT	void	set_732		__PR((char *pnt, unsigned int i));
-EXPORT	void	set_733		__PR((char *pnt, unsigned int i));
-EXPORT	int	get_731		__PR((char *p));
-EXPORT	int	get_732		__PR((char *p));
-EXPORT	int	get_733		__PR((char *p));
-LOCAL	int	xawrite		__PR((void *buffer, int size, int count,
-					FILE *file, int submode, BOOL islast));
-EXPORT	void	xfwrite		__PR((void *buffer, int size, int count,
-					FILE *file, int submode, BOOL islast));
-LOCAL 	int	assign_directory_addresses __PR((struct directory *node));
+void	set_721(char *pnt, unsigned int i);
+void	set_722(char *pnt, unsigned int i);
+void	set_723(char *pnt, unsigned int i);
+void	set_731(char *pnt, unsigned int i);
+void	set_732(char *pnt, unsigned int i);
+void	set_733(char *pnt, unsigned int i);
+int	get_731(char *p);
+int	get_732(char *p);
+int	get_733(char *p);
+static	int	xawrite(void *buffer, int size, int count, FILE *file, 
+							  int submode, BOOL islast);
+void	xfwrite(void *buffer, int size, int count, FILE *file, int submode, 
+				  BOOL islast);
+static 	int	assign_directory_addresses(struct directory *node);
 #ifdef APPLE_HYB
-LOCAL 	void	write_one_file	__PR((char *filename, off_t size,
-					FILE *outfile, off_t off));
+static 	void	write_one_file(char *filename, off_t size, FILE *outfile, 
+										off_t off);
 #else
-LOCAL 	void	write_one_file	__PR((char *filename, off_t size,
-					FILE *outfile));
+static 	void	write_one_file(char *filename, off_t size, FILE *outfile);
 #endif
-LOCAL 	void	write_files	__PR((FILE *outfile));
+static 	void	write_files(FILE *outfile);
 #if 0
-LOCAL 	void	dump_filelist	__PR((void));
+static 	void	dump_filelist	__PR((void));
 #endif
-LOCAL 	int	compare_dirs	__PR((const void *rr, const void *ll));
-EXPORT	int	sort_directory	__PR((struct directory_entry **sort_dir,
-						int rr));
-LOCAL 	int	root_gen	__PR((void));
-LOCAL 	BOOL	assign_file_addresses __PR((struct directory *dpnt));
-LOCAL 	void	free_one_directory  __PR((struct directory *dpnt));
-LOCAL 	void	free_directories __PR((struct directory *dpnt));
-EXPORT	void	generate_one_directory __PR((struct directory *dpnt,
-						FILE *outfile));
-LOCAL 	void	build_pathlist	__PR((struct directory *node));
-LOCAL 	int	compare_paths	__PR((void const *r, void const *l));
-LOCAL 	int	generate_path_tables __PR((void));
-EXPORT	void	memcpy_max	__PR((char *to, char *from, int max));
-EXPORT	void	outputlist_insert __PR((struct output_fragment *frag));
-LOCAL 	int	file_write	__PR((FILE *outfile));
-LOCAL 	int	pvd_write	__PR((FILE *outfile));
-LOCAL 	int	xpvd_write	__PR((FILE *outfile));
-LOCAL 	int	evd_write	__PR((FILE *outfile));
-LOCAL 	int	vers_write	__PR((FILE *outfile));
-LOCAL 	int	graftcp		__PR((char *to, char *from, char *ep));
-LOCAL 	int	pathcp		__PR((char *to, char *from, char *ep));
-LOCAL 	int	pathtab_write	__PR((FILE *outfile));
-LOCAL 	int	exten_write	__PR((FILE *outfile));
-EXPORT	int	oneblock_size	__PR((int starting_extent));
-LOCAL 	int	pathtab_size	__PR((int starting_extent));
-LOCAL 	int	startpad_size	__PR((int starting_extent));
-LOCAL 	int	interpad_size	__PR((int starting_extent));
-LOCAL 	int	endpad_size	__PR((int starting_extent));
-LOCAL 	int	file_gen	__PR((void));
-LOCAL 	int	dirtree_dump	__PR((void));
-LOCAL 	int	dirtree_fixup	__PR((int starting_extent));
-LOCAL 	int	dirtree_size	__PR((int starting_extent));
-LOCAL 	int	ext_size	__PR((int starting_extent));
-LOCAL 	int	dirtree_write	__PR((FILE *outfile));
-LOCAL 	int	dirtree_cleanup	__PR((FILE *outfile));
-LOCAL 	int	startpad_write	__PR((FILE *outfile));
-LOCAL 	int	interpad_write	__PR((FILE *outfile));
-LOCAL 	int	endpad_write	__PR((FILE *outfile));
+static 	int	compare_dirs(const void *rr, const void *ll);
+int	sort_directory(struct directory_entry **sort_dir, int rr);
+static 	int	root_gen(void);
+static 	BOOL	assign_file_addresses(struct directory *dpnt);
+static 	void	free_one_directory(struct directory *dpnt);
+static 	void	free_directories(struct directory *dpnt);
+void	generate_one_directory(struct directory *dpnt, FILE *outfile);
+static 	void	build_pathlist(struct directory *node);
+static 	int	compare_paths(void const *r, void const *l);
+static 	int	generate_path_tables(void);
+void	memcpy_max(char *to, char *from, int max);
+void	outputlist_insert(struct output_fragment *frag);
+static 	int	file_write(FILE *outfile);
+static 	int	pvd_write(FILE *outfile);
+static 	int	xpvd_write(FILE *outfile);
+static 	int	evd_write(FILE *outfile);
+static 	int	vers_write(FILE *outfile);
+static 	int	graftcp(char *to, char *from, char *ep);
+static 	int	pathcp(char *to, char *from, char *ep);
+static 	int	pathtab_write(FILE *outfile);
+static 	int	exten_write(FILE *outfile);
+int	oneblock_size(int starting_extent);
+static 	int	pathtab_size(int starting_extent);
+static 	int	startpad_size(int starting_extent);
+static 	int	interpad_size(int starting_extent);
+static 	int	endpad_size(int starting_extent);
+static 	int	file_gen(void);
+static 	int	dirtree_dump(void);
+static 	int	dirtree_fixup(int starting_extent);
+static 	int	dirtree_size(int starting_extent);
+static 	int	ext_size(int starting_extent);
+static 	int	dirtree_write(FILE *outfile);
+static 	int	dirtree_cleanup(FILE *outfile);
+static 	int	startpad_write(FILE *outfile);
+static 	int	interpad_write(FILE *outfile);
+static 	int	endpad_write(FILE *outfile);
 #ifdef APPLE_HYB
-LOCAL 	int	hfs_pad;
-LOCAL 	int	hfs_get_parms	__PR((char * key));
-LOCAL 	void	hfs_file_gen	__PR((int start_extent));
-LOCAL 	void	gen_prepboot	__PR((void));
-EXPORT	Ulong	get_adj_size	__PR((int Csize));
-EXPORT	int	adj_size	__PR((int Csize, int start_extent, int extra));
-EXPORT	void	adj_size_other	__PR((struct directory *dpnt));
-LOCAL 	int	hfs_hce_write	__PR((FILE * outfile));
-EXPORT	int	insert_padding_file __PR((int size));
+static 	int	hfs_pad;
+static 	int	hfs_get_parms(char *key);
+static 	void	hfs_file_gen(int start_extent);
+static 	void	gen_prepboot(void);
+Ulong	get_adj_size(int Csize);
+int	adj_size(int Csize, int start_extent, int extra);
+void	adj_size_other(struct directory *dpnt);
+static 	int	hfs_hce_write(FILE * outfile);
+int	insert_padding_file(int size);
 #endif	/* APPLE_HYB */
 
 #ifdef SORTING
-LOCAL 	int	compare_sort	__PR((const void * rr, const void * ll));
-LOCAL 	void	reassign_link_addresses	__PR((struct directory * dpnt));
-LOCAL 	int	sort_file_addresses __PR((void));
+static 	int	compare_sort(const void * rr, const void * ll);
+static 	void	reassign_link_addresses(struct directory * dpnt);
+static 	int	sort_file_addresses(void);
 #endif /* SORTING */
 
 /*
@@ -168,37 +165,29 @@
  */
 #define	FILL_SPACE(X)	memset(vol_desc.X, ' ', sizeof (vol_desc.X))
 
-EXPORT void
-set_721(pnt, i)
-	char		*pnt;
-	unsigned int	i;
+void
+set_721(char *pnt, unsigned int i)
 {
 	pnt[0] = i & 0xff;
 	pnt[1] = (i >> 8) & 0xff;
 }
 
-EXPORT void
-set_722(pnt, i)
-	char		*pnt;
-	unsigned int	i;
+void
+set_722(char *pnt, unsigned int i)
 {
 	pnt[0] = (i >> 8) & 0xff;
 	pnt[1] = i & 0xff;
 }
 
-EXPORT void
-set_723(pnt, i)
-	char		*pnt;
-	unsigned int	i;
+void
+set_723(char *pnt, unsigned int i)
 {
 	pnt[3] = pnt[0] = i & 0xff;
 	pnt[2] = pnt[1] = (i >> 8) & 0xff;
 }
 
-EXPORT void
-set_731(pnt, i)
-	char		*pnt;
-	unsigned int	i;
+void
+set_731(char *pnt, unsigned int i)
 {
 	pnt[0] = i & 0xff;
 	pnt[1] = (i >> 8) & 0xff;
@@ -206,10 +195,8 @@
 	pnt[3] = (i >> 24) & 0xff;
 }
 
-EXPORT void
-set_732(pnt, i)
-	char		*pnt;
-	unsigned int	i;
+void
+set_732(char *pnt, unsigned int i)
 {
 	pnt[3] = i & 0xff;
 	pnt[2] = (i >> 8) & 0xff;
@@ -217,10 +204,8 @@
 	pnt[0] = (i >> 24) & 0xff;
 }
 
-EXPORT void
-set_733(pnt, i)
-	char		*pnt;
-	unsigned int	i;
+void
+set_733(char *pnt, unsigned int i)
 {
 	pnt[7] = pnt[0] = i & 0xff;
 	pnt[6] = pnt[1] = (i >> 8) & 0xff;
@@ -228,9 +213,8 @@
 	pnt[4] = pnt[3] = (i >> 24) & 0xff;
 }
 
-EXPORT int
-get_731(p)
-	char	*p;
+int
+get_731(char *p)
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8)
@@ -238,9 +222,8 @@
 		| ((p[3] & 0xff) << 24));
 }
 
-EXPORT int
-get_732(p)
-	char	*p;
+int
+get_732(char *p)
 {
 	return ((p[3] & 0xff)
 		| ((p[2] & 0xff) << 8)
@@ -248,9 +231,8 @@
 		| ((p[0] & 0xff) << 24));
 }
 
-EXPORT int
-get_733(p)
-	char	*p;
+int
+get_733(char *p)
 {
 	return ((p[0] & 0xff)
 		| ((p[1] & 0xff) << 8)
@@ -258,14 +240,8 @@
 		| ((p[3] & 0xff) << 24));
 }
 
-EXPORT void
-xfwrite(buffer, size, count, file, submode, islast)
-	void	*buffer;
-	int	size;
-	int	count;
-	FILE	*file;
-	int	submode;
-	BOOL	islast;
+void
+xfwrite(void *buffer, int size, int count, FILE *file, int submode, BOOL islast)
 {
 	/*
 	 * This is a hack that could be made better.
@@ -333,14 +309,8 @@
 	}
 }
 
-LOCAL int
-xawrite(buffer, size, count, file, submode, islast)
-	void	*buffer;
-	int	size;
-	int	count;
-	FILE	*file;
-	int	submode;
-	BOOL	islast;
+static int
+xawrite(void *buffer, int size, int count, FILE *file, int submode, BOOL islast)
 {
 	register char	*p = buffer;
 	register int	amt = size * count;
@@ -391,24 +361,23 @@
 /*
  * use the deferred_write struct to store info about the hfs_boot_file
  */
-LOCAL struct deferred_write mac_boot;
+static struct deferred_write mac_boot;
 
 #endif	/* APPLE_HYB */
-LOCAL struct deferred_write	*dw_head = NULL,
+static struct deferred_write	*dw_head = NULL,
 				*dw_tail = NULL;
 
 unsigned int	last_extent_written = 0;
-LOCAL	Uint	path_table_index;
-EXPORT	time_t	begun;
+static	Uint	path_table_index;
+time_t	begun;
 
 /*
  * We recursively walk through all of the directories and assign extent
  * numbers to them.  We have already assigned extent numbers to everything that
  * goes in front of them
  */
-LOCAL int
-assign_directory_addresses(node)
-	struct directory	*node;
+static int
+assign_directory_addresses(struct directory *node)
 {
 	int		dir_size;
 	struct directory *dpnt;
@@ -450,18 +419,11 @@
 }
 
 #ifdef APPLE_HYB
-LOCAL void
-write_one_file(filename, size, outfile, off)
-	char		*filename;
-	off_t		size;
-	FILE		*outfile;
-	off_t		off;
+static void
+write_one_file(char *filename, off_t size, FILE *outfile, off_t off)
 #else
-LOCAL void
-write_one_file(filename, size, outfile)
-	char		*filename;
-	off_t		size;
-	FILE		*outfile;
+static void
+write_one_file(char *filename, off_t size, FILE *outfile)
 #endif	/* APPLE_HYB */
 {
 	/*
@@ -580,9 +542,8 @@
 	fclose(infile);
 }/* write_one_file(... */
 
-LOCAL void
-write_files(outfile)
-	FILE	*outfile;
+static void
+write_files(FILE *outfile)
 {
 	struct deferred_write	*dwpnt,
 				*dwnext;
@@ -658,7 +619,7 @@
 }/* write_files(... */
 
 #if 0
-LOCAL void
+static void
 dump_filelist()
 {
 	struct deferred_write *dwpnt;
@@ -673,10 +634,8 @@
 
 #endif
 
-LOCAL int
-compare_dirs(rr, ll)
-	const void	*rr;
-	const void	*ll;
+static int
+compare_dirs(const void *rr, const void *ll)
 {
 	char		*rpnt,
 			*lpnt;
@@ -808,10 +767,8 @@
  *
  * Notes:		Returns 0 if OK, returns > 0 if an error occurred.
  */
-EXPORT int
-sort_directory(sort_dir, rr)
-	struct directory_entry **sort_dir;
-	int		rr;
+int
+sort_directory(struct directory_entry **sort_dir, int rr)
 {
 	int		dcount = 0;
 	int		xcount = 0;
@@ -896,7 +853,7 @@
 	return (sort_goof);
 }
 
-LOCAL int
+static int
 root_gen()
 {
 	init_fstatbuf();
@@ -919,10 +876,8 @@
 /*
  *	sorts deferred_write entries based on the sort weight
  */
-LOCAL int
-compare_sort(rr, ll)
-	const void	*rr;
-	const void	*ll;
+static int
+compare_sort(const void *rr, const void *ll)
 {
 	struct deferred_write	**r;
 	struct deferred_write	**l;
@@ -944,9 +899,8 @@
  *	reassign start extents to files that are "hard links" to
  *	files that may have been sorted
  */
-LOCAL void
-reassign_link_addresses(dpnt)
-	struct directory	*dpnt;
+static void
+reassign_link_addresses(struct directory *dpnt)
 {
 	struct directory_entry	*s_entry;
 	struct file_hash	*s_hash;
@@ -976,7 +930,7 @@
 /*
  *	sort files in order of the given sort weight
  */
-LOCAL int
+static int
 sort_file_addresses()
 {
 	struct deferred_write	*dwpnt;
@@ -1056,9 +1010,8 @@
 
 
 
-LOCAL BOOL
-assign_file_addresses(dpnt)
-	struct directory	*dpnt;
+static BOOL
+assign_file_addresses(struct directory *dpnt)
 {
 	struct directory *finddir;
 	struct directory_entry *s_entry;
@@ -1360,9 +1313,8 @@
 	return (ret);
 }/* assign_file_addresses(... */
 
-LOCAL void
-free_one_directory(dpnt)
-	struct directory	*dpnt;
+static void
+free_one_directory(struct directory *dpnt)
 {
 	struct directory_entry *s_entry;
 	struct directory_entry *s_entry_d;
@@ -1395,9 +1347,8 @@
 	dpnt->contents = NULL;
 }/* free_one_directory(... */
 
-LOCAL void
-free_directories(dpnt)
-	struct directory	*dpnt;
+static void
+free_directories(struct directory *dpnt)
 {
 	while (dpnt) {
 		free_one_directory(dpnt);
@@ -1407,10 +1358,8 @@
 	}
 }
 
-EXPORT void
-generate_one_directory(dpnt, outfile)
-	struct directory	*dpnt;
-	FILE			*outfile;
+void
+generate_one_directory(struct directory *dpnt, FILE *outfile)
 {
 	unsigned int	ce_address = 0;
 	char		*ce_buffer;
@@ -1597,9 +1546,8 @@
 	}
 }/* generate_one_directory(... */
 
-LOCAL void
-build_pathlist(node)
-	struct directory	*node;
+static void
+build_pathlist(struct directory *node)
 {
 	struct directory *dpnt;
 
@@ -1616,10 +1564,8 @@
 	}
 }/* build_pathlist(... */
 
-LOCAL int
-compare_paths(r, l)
-	void const	*r;
-	void const	*l;
+static int
+compare_paths(void const *r, void const *l)
 {
 	struct directory const *ll = *(struct directory * const *) l;
 	struct directory const *rr = *(struct directory * const *) r;
@@ -1634,7 +1580,7 @@
 
 }/* compare_paths(... */
 
-LOCAL int
+static int
 generate_path_tables()
 {
 	struct directory_entry *de = NULL;
@@ -1772,11 +1718,8 @@
 	return (0);
 }/* generate_path_tables(... */
 
-EXPORT void
-memcpy_max(to, from, max)
-	char	*to;
-	char	*from;
-	int	max;
+void
+memcpy_max(char *to, char *from, int max)
 {
 	int	n = strlen(from);
 
@@ -1787,9 +1730,8 @@
 
 }/* memcpy_max(... */
 
-EXPORT void
-outputlist_insert(frag)
-	struct output_fragment *frag;
+void
+outputlist_insert(struct output_fragment *frag)
 {
 	struct output_fragment *nfrag;
 
@@ -1805,9 +1747,8 @@
 	}
 }
 
-LOCAL int
-file_write(outfile)
-	FILE	*outfile;
+static int
+file_write(FILE *outfile)
 {
 	Uint	should_write;
 
@@ -1931,9 +1872,8 @@
 /*
  * Function to write the PVD for the disc.
  */
-LOCAL int
-pvd_write(outfile)
-	FILE	*outfile;
+static int
+pvd_write(FILE *outfile)
 {
 	char		iso_time[17];
 	int		should_write;
@@ -2059,9 +1999,8 @@
 /*
  * Function to write the Extended PVD for the disc.
  */
-LOCAL int
-xpvd_write(outfile)
-	FILE	*outfile;
+static int
+xpvd_write(FILE *outfile)
 {
 	vol_desc.type[0] = ISO_VD_SUPPLEMENTARY;
 	vol_desc.version[0] = 2;
@@ -2077,9 +2016,8 @@
 /*
  * Function to write the EVD for the disc.
  */
-LOCAL int
-evd_write(outfile)
-	FILE	*outfile;
+static int
+evd_write(FILE *outfile)
 {
 	struct iso_primary_descriptor evol_desc;
 
@@ -2100,9 +2038,8 @@
 /*
  * Function to write the version information for the disc.
  */
-LOCAL int
-vers_write(outfile)
-	FILE	*outfile;
+static int
+vers_write(FILE *outfile)
 {
 	char		vers[SECTOR_SIZE+1];
 	int		X_ac;
@@ -2160,11 +2097,8 @@
 /*
  * Avoid to write unwanted information into the version info string.
  */
-LOCAL int
-graftcp(to, from, ep)
-	char	*to;
-	char	*from;
-	char	*ep;
+static int
+graftcp(char *to, char *from, char *ep)
 {
 	int	len = strlen(from);
 	char	*node = NULL;
@@ -2186,11 +2120,8 @@
 	return (len + pathcp(to, node, ep));
 }
 
-LOCAL int
-pathcp(to, from, ep)
-	char	*to;
-	char	*from;
-	char	*ep;
+static int
+pathcp(char *to, char *from, char *ep)
 {
 	int	len = strlen(from);
 	char	*p;
@@ -2222,9 +2153,8 @@
 /*
  * Function to write the path table for the disc.
  */
-LOCAL int
-pathtab_write(outfile)
-	FILE	*outfile;
+static int
+pathtab_write(FILE *outfile)
 {
 	/* Next we write the path tables */
 	jtwrite(path_table_l, path_blocks << 11, 1, 0, FALSE);
@@ -2240,9 +2170,8 @@
 	return (0);
 }
 
-LOCAL int
-exten_write(outfile)
-	FILE	*outfile;
+static int
+exten_write(FILE *outfile)
 {
 	jtwrite(extension_record, SECTOR_SIZE, 1, 0, FALSE);
 	xfwrite(extension_record, SECTOR_SIZE, 1, outfile, 0, FALSE);
@@ -2253,9 +2182,8 @@
 /*
  * Functions to describe padding block at the start of the disc.
  */
-EXPORT int
-oneblock_size(starting_extent)
-	int	starting_extent;
+int
+oneblock_size(int starting_extent)
 {
 	last_extent++;
 	return (0);
@@ -2264,9 +2192,8 @@
 /*
  * Functions to describe path table size.
  */
-LOCAL int
-pathtab_size(starting_extent)
-	int	starting_extent;
+static int
+pathtab_size(int starting_extent)
 {
 	path_table[0] = starting_extent;
 
@@ -2280,9 +2207,8 @@
 /*
  * Functions to describe padding blocks before PVD.
  */
-LOCAL int
-startpad_size(starting_extent)
-	int	starting_extent;
+static int
+startpad_size(int starting_extent)
 {
 	last_extent = session_start + 16;
 	return (0);
@@ -2291,9 +2217,8 @@
 /*
  * Functions to describe padding blocks between sections.
  */
-LOCAL int
-interpad_size(starting_extent)
-	int	starting_extent;
+static int
+interpad_size(int starting_extent)
 {
 	int	emod = 0;
 
@@ -2310,16 +2235,15 @@
 /*
  * Functions to describe padding blocks at end of disk.
  */
-LOCAL int
-endpad_size(starting_extent)
-	int	starting_extent;
+static int
+endpad_size(int starting_extent)
 {
 	starting_extent += 150;			/* 150 pad blocks (post gap) */
 	last_extent = starting_extent;
 	return (0);
 }
 
-LOCAL int
+static int
 file_gen()
 {
 #ifdef APPLE_HYB
@@ -2366,7 +2290,7 @@
 	return (0);
 }
 
-LOCAL int
+static int
 dirtree_dump()
 {
 	if (verbose > 2) {
@@ -2375,9 +2299,8 @@
 	return (0);
 }
 
-LOCAL int
-dirtree_fixup(starting_extent)
-	int	starting_extent;
+static int
+dirtree_fixup(int starting_extent)
 {
 	if (use_RockRidge && reloc_dir)
 		finish_cl_pl_entries();
@@ -2387,17 +2310,15 @@
 	return (0);
 }
 
-LOCAL int
-dirtree_size(starting_extent)
-	int	starting_extent;
+static int
+dirtree_size(int starting_extent)
 {
 	assign_directory_addresses(root);
 	return (0);
 }
 
-LOCAL int
-ext_size(starting_extent)
-	int	starting_extent;
+static int
+ext_size(int starting_extent)
 {
 	extern int		extension_record_size;
 	struct directory_entry *s_entry;
@@ -2412,25 +2333,22 @@
 	return (0);
 }
 
-LOCAL int
-dirtree_write(outfile)
-	FILE	*outfile;
+static int
+dirtree_write(FILE *outfile)
 {
 	generate_iso9660_directories(root, outfile);
 	return (0);
 }
 
-LOCAL int
-dirtree_cleanup(outfile)
-	FILE	*outfile;
+static int
+dirtree_cleanup(FILE *outfile)
 {
 	free_directories(root);
 	return (0);
 }
 
-LOCAL int
-startpad_write(outfile)
-	FILE	*outfile;
+static int
+startpad_write(FILE *outfile)
 {
 	char	buffer[SECTOR_SIZE];
 	int	i;
@@ -2449,9 +2367,8 @@
 	return (0);
 }
 
-LOCAL int
-interpad_write(outfile)
-	FILE	*outfile;
+static int
+interpad_write(FILE *outfile)
 {
 	char	buffer[SECTOR_SIZE];
 	int	i;
@@ -2474,9 +2391,8 @@
 	return (0);
 }
 
-LOCAL int
-endpad_write(outfile)
-	FILE	*outfile;
+static int
+endpad_write(FILE *outfile)
 {
 	char	buffer[SECTOR_SIZE];
 	int	i;
@@ -2498,9 +2414,8 @@
  *	hfs_get_parms:	get HFS parameters from the command line
  */
 
-LOCAL int
-hfs_get_parms(key)
-	char	*key;
+static int
+hfs_get_parms(char *key)
 {
 	int	ret = 0;
 	char	*p;
@@ -2519,9 +2434,8 @@
 /*
  *	hfs_file_gen:	set up "fake" HFS volume using the ISO9660 tree
  */
-LOCAL void
-hfs_file_gen(start_extent)
-	int	start_extent;
+static void
+hfs_file_gen(int start_extent)
 {
 	int	Csize;	/* clump size for HFS vol */
 	int	loop;
@@ -2664,7 +2578,7 @@
 }
 
 #ifdef PREP_BOOT
-LOCAL void
+static void
 gen_prepboot()
 {
 	/*
@@ -2689,9 +2603,8 @@
  *	get_adj_size:	get the ajusted size of the volume with the HFS
  *			allocation block size for each file
  */
-EXPORT Ulong
-get_adj_size(Csize)
-	int	Csize;
+Ulong
+get_adj_size(int Csize)
 {
 	struct deferred_write *dw;
 	Ulong		size = 0;
@@ -2719,11 +2632,8 @@
  *	adj_size:	adjust the ISO record entries for all files
  *			based on the HFS allocation block size
  */
-EXPORT int
-adj_size(Csize, start_extent, extra)
-	int	Csize;
-	int	start_extent;
-	int	extra;
+int
+adj_size(int Csize, int start_extent, int extra)
 {
 	struct deferred_write *dw;
 	struct directory_entry *s_entry;
@@ -2774,9 +2684,8 @@
  *			to an existing file (i.e. not have a deferred_write
  *			entry of it's own
  */
-EXPORT void
-adj_size_other(dpnt)
-	struct directory	*dpnt;
+void
+adj_size_other(struct directory *dpnt)
 {
 	struct directory_entry *s_entry;
 	struct file_hash *s_hash;
@@ -2819,9 +2728,8 @@
 /*
  *	hfs_hce_write:	write out the HFS header stuff
  */
-LOCAL int
-hfs_hce_write(outfile)
-	FILE	*outfile;
+static int
+hfs_hce_write(FILE *outfile)
 {
 	char	buffer[SECTOR_SIZE];
 	int	n = 0;
@@ -2863,9 +2771,8 @@
  *
  *	XXX If we ever need to write more then 2 GB, make size off_t
  */
-EXPORT int
-insert_padding_file(size)
-	int	size;
+int
+insert_padding_file(int size)
 {
 	struct deferred_write *dwpnt;
 

Modified: nonameyet/branches/cleanup/readcd/io.c
===================================================================
--- nonameyet/branches/cleanup/readcd/io.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/readcd/io.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -47,20 +47,19 @@
 	int	dummy;
 };
 
-static	char	*skipwhite	__PR((const char *));
-static	void	prt_std		__PR((char *, long, long, long, struct disk *));
-BOOL	cvt_std		__PR((char *, long *, long, long, struct disk *));
-extern	BOOL	getvalue	__PR((char *, long *, long, long,
-				void (*)(char *, long, long, long, struct disk *),
-				BOOL (*)(char *, long *, long, long, struct disk *),
-				struct disk *));
-extern	BOOL	getlong		__PR((char *, long *, long, long));
-extern	BOOL	getint		__PR((char *, int *, int, int));
-extern	BOOL	yes		__PR((char *, ...));
+static	char	*skipwhite(const char *);
+static	void	prt_std(char *, long, long, long, struct disk *);
+BOOL	cvt_std(char *, long *, long, long, struct disk *);
+extern	BOOL	getvalue(char *, long *, long, long,
+								void (*)(char *, long, long, long, struct disk *),
+								BOOL (*)(char *, long *, long, long, struct disk *),
+								struct disk *);
+extern	BOOL	getlong(char *, long *, long, long);
+extern	BOOL	getint(char *, int *, int, int);
+extern	BOOL	yes(char *, ...);
 
 static
-char *skipwhite(s)
-		 const char	*s;
+char *skipwhite(const char *s)
 {
 	register const Uchar	*p = (const Uchar *)s;
 
@@ -75,12 +74,7 @@
 /* ARGSUSED */
 
 BOOL
-cvt_std(linep, lp, mini, maxi, dp)
-	char	*linep;
-	long	*lp;
-	long	mini;
-	long	maxi;
-	struct disk	*dp;
+cvt_std(char *linep, long *lp, long mini, long maxi, struct disk *dp)
 {
 	long	l	= -1L;
 
@@ -122,25 +116,16 @@
 
 /* ARGSUSED */
 static void
-prt_std(s, l, mini, maxi, dp)
-	char	*s;
-	long	l;
-	long	mini;
-	long	maxi;
-	struct disk *dp;
+prt_std(char *s, long l, long mini, long maxi, struct disk *dp)
 {
 	printf("%s %ld (%ld - %ld)/<cr>:", s, l, mini, maxi);
 }
 
 
-BOOL getvalue(s, lp, mini, maxi, prt, cvt, dp)
-	char	*s;
-	long	*lp;
-	long	mini;
-	long	maxi;
-	void	(*prt) __PR((char *, long, long, long, struct disk *));
-	BOOL	(*cvt) __PR((char *, long *, long, long, struct disk *));
-	struct disk	*dp;
+BOOL getvalue(char *s, long *lp, long mini, long maxi, 
+				  void  (*prt)(char *, long, long, long, struct disk *), 
+	  			  BOOL  (*cvt)(char *, long *, long, long, struct disk *), 
+				  struct disk *dp)
 {
 	char	line[128];
 	char	*linep;
@@ -170,21 +155,13 @@
 }
 
 
-BOOL getlong(s, lp, mini, maxi)
-	char	*s;
-	long	*lp;
-	long	mini;
-	long	maxi;
+BOOL getlong(char *s, long *lp, long mini, long maxi)
 {
 	return (getvalue(s, lp, mini, maxi, prt_std, cvt_std, (void *)0));
 }
 
 
-BOOL getint(s, ip, mini, maxi)
-	char	*s;
-	int	*ip;
-	int	mini;
-	int	maxi;
+BOOL getint(char *s, int *ip, int mini, int maxi)
 {
 	long	l = *ip;
 	BOOL	ret;
@@ -195,24 +172,13 @@
 }
 
 /* VARARGS1 */
-#ifdef	PROTOTYPES
 BOOL yes(char *form, ...)
-#else
-
-BOOL yes(form, va_alist)
-	char	*form;
-	va_dcl
-#endif
 {
 	va_list	args;
 	char okbuf[10];
 
 again:
-#ifdef	PROTOTYPES
 	va_start(args, form);
-#else
-	va_start(args);
-#endif
 	printf("%r", form, args);
 	va_end(args);
 	flush();

Modified: nonameyet/branches/cleanup/readcd/readcd.c
===================================================================
--- nonameyet/branches/cleanup/readcd/readcd.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/readcd/readcd.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -80,8 +80,8 @@
 #define	CONCAT(a, b)	a/**/b
 #endif
 
-extern	BOOL	getlong		__PR((char *, long *, long, long));
-extern	BOOL	getint		__PR((char *, int *, int, int));
+extern	BOOL	getlong(char *, long *, long, long);
+extern	BOOL	getint(char *, int *, int, int);
 
 typedef struct {
 	long	start;
@@ -109,76 +109,82 @@
 	char	oerr[3];
 } exargs;
 
-EXPORT	BOOL	cvt_cyls	__PR((void));
-EXPORT	BOOL	cvt_bcyls	__PR((void));
-EXPORT	void	print_defect_list __PR((void));
-LOCAL	void	usage		__PR((int ret));
-EXPORT	int	main		__PR((int ac, char **av));
-LOCAL	void	intr		__PR((int sig));
-LOCAL	void	exscsi		__PR((int excode, void *arg));
-LOCAL	void	excdr		__PR((int excode, void *arg));
-LOCAL	int	prstats		__PR((void));
-LOCAL	int	prstats_silent	__PR((void));
-LOCAL	void	dorw		__PR((SCSI *scgp, char *filename, char *sectors));
-LOCAL	void	doit		__PR((SCSI *scgp));
-LOCAL	void	read_disk	__PR((SCSI *scgp, parm_t *parmp));
+BOOL	cvt_cyls(void);
+BOOL	cvt_bcyls(void);
+void	print_defect_list(void);
+static	void	usage(int ret);
+static	void	intr(int sig);
+static	void	exscsi(int excode, void *arg);
+static	void	excdr(int excode, void *arg);
+static	int	prstats(void);
+static	int	prstats_silent(void);
+static	void	dorw(SCSI *scgp, char *filename, char *sectors);
+static	void	doit(SCSI *scgp);
+static	void	read_disk(SCSI *scgp, parm_t *parmp);
 #ifdef	CLONE_WRITE
-LOCAL	void	readcd_disk	__PR((SCSI *scgp, parm_t *parmp));
-LOCAL	void	read_lin	__PR((SCSI *scgp, parm_t *parmp));
-LOCAL	int	read_secheader	__PR((SCSI *scgp, long addr));
-LOCAL	int	read_ftoc	__PR((SCSI *scgp, parm_t *parmp, BOOL do_sectype));
-LOCAL	void	read_sectypes	__PR((SCSI *scgp, FILE *f));
-LOCAL	void	get_sectype	__PR((SCSI *scgp, long addr, char *st));
+static	void	readcd_disk(SCSI *scgp, parm_t *parmp);
+static	void	read_lin(SCSI *scgp, parm_t *parmp);
+static	int	read_secheader(SCSI *scgp, long addr);
+static	int	read_ftoc(SCSI *scgp, parm_t *parmp, BOOL do_sectype);
+static	void	read_sectypes(SCSI *scgp, FILE *f);
+static	void	get_sectype(SCSI *scgp, long addr, char *st);
 #endif
 
-LOCAL	void	readc2_disk	__PR((SCSI *scgp, parm_t *parmp));
-LOCAL	int	fread_data	__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
+static	void	readc2_disk(SCSI *scgp, parm_t *parmp);
+static	int	fread_data(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, 
+								  int cnt);
 #ifdef	CLONE_WRITE
-LOCAL	int	fread_2448	__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
-LOCAL	int	fread_2448_16	__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
-LOCAL	int	fread_2352	__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
-LOCAL	int	fread_lin	__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
+static	int	fread_2448(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, 
+								  int cnt);
+static	int	fread_2448_16(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, 
+									  int cnt);
+static	int	fread_2352(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, 
+								  int cnt);
+static	int	fread_lin(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, 
+								 int cnt);
 #endif
-LOCAL	int	bits		__PR((int c));
-LOCAL	int	bitidx		__PR((int c));
-LOCAL	int	fread_c2	__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
+static	int	bits(int c);
+static	int	bitidx(int c);
+static	int	fread_c2(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, 
+								int cnt);
 
-LOCAL	int	fdata_null	__PR((rparm_t *rp, caddr_t bp, long addr, int cnt));
-LOCAL	int	fdata_c2	__PR((rparm_t *rp, caddr_t bp, long addr, int cnt));
+static	int	fdata_null(rparm_t *rp, caddr_t bp, long addr, int cnt);
+static	int	fdata_c2(rparm_t *rp, caddr_t bp, long addr, int cnt);
 
 #ifdef	used
-LOCAL	int read_scsi_g1	__PR((SCSI *scgp, caddr_t bp, long addr, int cnt));
+static	int read_scsi_g1(SCSI *scgp, caddr_t bp, long addr, int cnt);
 #endif
 
-EXPORT	int	write_scsi	__PR((SCSI *scgp, caddr_t bp, long addr, int cnt));
-EXPORT	int	write_g0	__PR((SCSI *scgp, caddr_t bp, long addr, int cnt));
-EXPORT	int	write_g1	__PR((SCSI *scgp, caddr_t bp, long addr, int cnt));
+int	write_scsi(SCSI *scgp, caddr_t bp, long addr, int cnt);
+int	write_g0(SCSI *scgp, caddr_t bp, long addr, int cnt);
+int	write_g1(SCSI *scgp, caddr_t bp, long addr, int cnt);
 
 #ifdef	used
-LOCAL	void	Xrequest_sense	__PR((SCSI *scgp));
+static	void	Xrequest_sense(SCSI *scgp);
 #endif
-LOCAL	int	read_retry	__PR((SCSI *scgp, caddr_t bp, long addr, long cnt,
-					int (*rfunc)(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt),
-					rparm_t *rp));
-LOCAL	void	read_generic	__PR((SCSI *scgp, parm_t *parmp,
-					int (*rfunc)(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt),
-					rparm_t *rp,
-					int (*dfunc)(rparm_t *rp, caddr_t bp, long addr, int cnt)
-));
-LOCAL	void	write_disk	__PR((SCSI *scgp, parm_t *parmp));
-LOCAL	int	choice		__PR((int n));
-LOCAL	void	ra		__PR((SCSI *scgp));
+static	int	read_retry(SCSI *scgp, caddr_t bp, long addr, long cnt,
+								  int (*rfunc)(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt),
+								  rparm_t *rp);
+static	void	read_generic(SCSI *scgp, parm_t *parmp,
+									 int (*rfunc)(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt),
+									 rparm_t *rp,
+									 int (*dfunc)(rparm_t *rp, caddr_t bp, long addr, int cnt));
+static	void	write_disk(SCSI *scgp, parm_t *parmp);
+static	int	choice(int n);
+static	void	ra(SCSI *scgp);
 
-EXPORT	int	read_da		__PR((SCSI *scgp, caddr_t bp, long addr, int cnt, int framesize, int subcode));
-EXPORT	int	read_cd		__PR((SCSI *scgp, caddr_t bp, long addr, int cnt, int framesize, int data, int subch));
+int	read_da(SCSI *scgp, caddr_t bp, long addr, int cnt, int framesize, 
+				  int subcode);
+int	read_cd(SCSI *scgp, caddr_t bp, long addr, int cnt, int framesize, 
+				  int data, int subch);
 
-LOCAL	void	oldmode		__PR((SCSI *scgp, int *errp, int *retrp));
-LOCAL	void	domode		__PR((SCSI *scgp, int err, int retr));
+static	void	oldmode(SCSI *scgp, int *errp, int *retrp);
+static	void	domode(SCSI *scgp, int err, int retr);
 
-LOCAL	void	qpto96		__PR((Uchar *sub, Uchar *subq, int dop));
-LOCAL	void	ovtime		__PR((SCSI *scgp));
-LOCAL	void	add_bad		__PR((long addr));
-LOCAL	void	print_bad	__PR((void));
+static	void	qpto96(Uchar *sub, Uchar *subq, int dop);
+static	void	ovtime(SCSI *scgp);
+static	void	add_bad(long addr);
+static	void	print_bad(void);
 
 struct timeval	starttime;
 struct timeval	stoptime;
@@ -216,9 +222,8 @@
 /*XXX*/EXPORT	BOOL cvt_bcyls() { return (FALSE); }
 /*XXX*/EXPORT	void print_defect_list() {}
 
-LOCAL void
-usage(ret)
-	int	ret;
+static void
+usage(int ret)
 {
 	error("Usage:\treadcd [options]\n");
 	error("options:\n");
@@ -259,10 +264,8 @@
 /* CSTYLED */
 char	opts[]   = "debug#,d+,kdebug#,kd#,timeout#,quiet,q,verbose+,v+,Verbose+,V+,x+,xd#,silent,s,help,h,version,scanbus,dev*,sectors*,w,c2scan,fulltoc,clone,noerror,nocorr,notrunc,retries#,factor,f*,speed#,ts&,overhead,meshpoints#";
 
-EXPORT int
-main(ac, av)
-	int	ac;
-	char	*av[];
+int
+main(int argc, char *argv[])
 {
 	char	*dev = NULL;
 	int	fcount;
@@ -284,10 +287,10 @@
 	char	*filename = NULL;
 	char	*sectors = NULL;
 
-	save_args(ac, av);
+	save_args(argc, argv);
 
-	cac = --ac;
-	cav = ++av;
+	cac = --argc;
+	cav = ++argv;
 
 	if (getallargs(&cac, &cav, opts,
 			&debug, &debug,
@@ -321,8 +324,8 @@
 	}
 
 	fcount = 0;
-	cac = ac;
-	cav = av;
+	cac = argc;
+	cav = argv;
 
 	while (getfiles(&cac, &cav, opts) > 0) {
 		fcount++;
@@ -547,9 +550,8 @@
  * XXX da meistens das letzte SCSI Kommando noch laeuft.
  * XXX Eine Loesung waere ein Abort Callback in SCSI *.
  */
-LOCAL void
-intr(sig)
-	int	sig;
+static void
+intr(int sig)
 {
 	didintr++;
 	exsig = sig;
@@ -557,10 +559,8 @@
 }
 
 /* ARGSUSED */
-LOCAL void
-exscsi(excode, arg)
-	int	excode;
-	void	*arg;
+static void
+exscsi(int excode, void *arg)
 {
 	struct exargs	*exp = (struct exargs *)arg;
 		int	i;
@@ -590,10 +590,8 @@
 	}
 }
 
-LOCAL void
-excdr(excode, arg)
-	int	excode;
-	void	*arg;
+static void
+excdr(int excode, void *arg)
 {
 	exscsi(excode, arg);
 
@@ -605,7 +603,7 @@
 /*
  * Return milliseconds since start time.
  */
-LOCAL int
+static int
 prstats()
 {
 	int	sec;
@@ -633,7 +631,7 @@
 /*
  * Return milliseconds since start time, but be silent this time.
  */
-LOCAL int
+static int
 prstats_silent()
 {
 	int	sec;
@@ -657,11 +655,8 @@
 	return (1000*sec + (usec / 1000));
 }
 
-LOCAL void
-dorw(scgp, filename, sectors)
-	SCSI	*scgp;
-	char	*filename;
-	char	*sectors;
+static void
+dorw(SCSI *scgp, char *filename, char *sectors)
 {
 	parm_t	params;
 	char	*p = NULL;
@@ -720,9 +715,8 @@
 		read_disk(scgp, &params);
 }
 
-LOCAL void
-doit(scgp)
-	SCSI	*scgp;
+static void
+doit(SCSI *scgp)
 {
 	int	i = 0;
 	parm_t	params;
@@ -765,10 +759,8 @@
 	}
 }
 
-LOCAL void
-read_disk(scgp, parmp)
-	SCSI	*scgp;
-	parm_t	*parmp;
+static void
+read_disk(SCSI *scgp, parm_t *parmp)
 {
 	rparm_t	rp;
 
@@ -786,16 +778,14 @@
 }
 
 #ifdef	CLONE_WRITE
-LOCAL void
-readcd_disk(scgp, parmp)
-	SCSI	*scgp;
-	parm_t	*parmp;
+static void
+readcd_disk(SCSI *scgp, parm_t *parmp)
 {
 	rparm_t	rp;
 	int	osecsize = 2048;
 	int	oerr = 0;
 	int	oretr = 10;
-	int	(*funcp)__PR((SCSI *_scgp, rparm_t *_rp, caddr_t bp, long addr, int cnt));
+	int	(*funcp)(SCSI *_scgp, rparm_t *_rp, caddr_t bp, long addr, int cnt);
 
 	scgp->silent++;
 	if (read_capacity(scgp) >= 0)
@@ -843,10 +833,8 @@
 }
 
 /* ARGSUSED */
-LOCAL void
-read_lin(scgp, parmp)
-	SCSI	*scgp;
-	parm_t	*parmp;
+static void
+read_lin(SCSI *scgp, parm_t *parmp)
 {
 	parm_t	parm;
 	rparm_t	rp;
@@ -869,10 +857,8 @@
 	read_generic(scgp, &parm, fread_lin, &rp, fdata_null);
 }
 
-LOCAL int
-read_secheader(scgp, addr)
-	SCSI	*scgp;
-	long	addr;
+static int
+read_secheader(SCSI *scgp, long addr)
 {
 	rparm_t	rp;
 	int	osecsize = 2048;
@@ -907,11 +893,8 @@
 }
 
 /* ARGSUSED */
-LOCAL int
-read_ftoc(scgp, parmp, do_sectype)
-	SCSI	*scgp;
-	parm_t	*parmp;
-	BOOL	do_sectype;
+static int
+read_ftoc(SCSI *scgp, parm_t *parmp, BOOL do_sectype)
 {
 	FILE	*f;
 	int	i;
@@ -992,10 +975,8 @@
 	return (0);
 }
 
-LOCAL void
-read_sectypes(scgp, f)
-	SCSI	*scgp;
-	FILE	*f;
+static void
+read_sectypes(SCSI *scgp, FILE *f)
 {
 	char	sect;
 
@@ -1016,11 +997,8 @@
 	}
 }
 
-LOCAL void
-get_sectype(scgp, addr, st)
-	SCSI	*scgp;
-	long	addr;
-	char	*st;
+static void
+get_sectype(SCSI *scgp, long addr, char *st)
 {
 	char	*synchdr = "\0\377\377\377\377\377\377\377\377\377\377\0";
 	int	sectype = SECT_AUDIO;
@@ -1096,10 +1074,8 @@
 
 char	zeroblk[512];
 
-LOCAL void
-readc2_disk(scgp, parmp)
-	SCSI	*scgp;
-	parm_t	*parmp;
+static void
+readc2_disk(SCSI *scgp, parm_t *parmp)
 {
 	rparm_t	rp;
 	int	osecsize = 2048;
@@ -1143,25 +1119,15 @@
 }
 
 /* ARGSUSED */
-LOCAL int
-fread_data(scgp, rp, bp, addr, cnt)
-	SCSI	*scgp;
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fread_data(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	return (read_g1(scgp, bp, addr, cnt));
 }
 
 #ifdef	CLONE_WRITE
-LOCAL int
-fread_2448(scgp, rp, bp, addr, cnt)
-	SCSI	*scgp;
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fread_2448(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	if (rp->ismmc) {
 		return (read_cd(scgp, bp, addr, cnt, rp->secsize,
@@ -1176,13 +1142,8 @@
 	}
 }
 
-LOCAL int
-fread_2448_16(scgp, rp, bp, addr, cnt)
-	SCSI	*scgp;
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fread_2448_16(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 
 	if (rp->ismmc) {
@@ -1224,13 +1185,8 @@
 	}
 }
 
-LOCAL int
-fread_2352(scgp, rp, bp, addr, cnt)
-	SCSI	*scgp;
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fread_2352(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	if (rp->ismmc) {
 		return (read_cd(scgp, bp, addr, cnt, rp->secsize,
@@ -1247,13 +1203,8 @@
 	}
 }
 
-LOCAL int
-fread_lin(scgp, rp, bp, addr, cnt)
-	SCSI	*scgp;
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fread_lin(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	if (addr != ULONG_C(0xF0000000))
 		addr = ULONG_C(0xFFFFFFFF);
@@ -1266,9 +1217,8 @@
 }
 #endif	/* CLONE_WRITE */
 
-LOCAL int
-bits(c)
-	int	c;
+static int
+bits(int c)
 {
 	int	n = 0;
 
@@ -1291,9 +1241,8 @@
 	return (n);
 }
 
-LOCAL int
-bitidx(c)
-	int	c;
+static int
+bitidx(int c)
 {
 	if (c & 0x80)
 		return (0);
@@ -1314,13 +1263,8 @@
 	return (-1);
 }
 
-LOCAL int
-fread_c2(scgp, rp, bp, addr, cnt)
-	SCSI	*scgp;
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fread_c2(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	if (rp->ismmc) {
 		return (read_cd(scgp, bp, addr, cnt, rp->secsize,
@@ -1337,22 +1281,14 @@
 }
 
 /* ARGSUSED */
-LOCAL int
-fdata_null(rp, bp, addr, cnt)
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fdata_null(rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	return (0);
 }
 
-LOCAL int
-fdata_c2(rp, bp, addr, cnt)
-	rparm_t	*rp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+fdata_c2(rparm_t *rp, caddr_t bp, long addr, int cnt)
 {
 	int	i;
 	int	j;
@@ -1382,12 +1318,8 @@
 }
 
 #ifdef	used
-LOCAL int
-read_scsi_g1(scgp, bp, addr, cnt)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+static int
+read_scsi_g1(SCSI *scgp, caddr_t bp, long addr, int cnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1411,12 +1343,8 @@
 
 #define	G0_MAXADDR	0x1FFFFFL
 
-EXPORT int
-write_scsi(scgp, bp, addr, cnt)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+int
+write_scsi(SCSI *scgp, caddr_t bp, long addr, int cnt)
 {
 	if (addr <= G0_MAXADDR)
 		return (write_g0(scgp, bp, addr, cnt));
@@ -1424,12 +1352,8 @@
 		return (write_g1(scgp, bp, addr, cnt));
 }
 
-EXPORT int
-write_g0(scgp, bp, addr, cnt)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+int
+write_g0(SCSI *scgp, caddr_t bp, long addr, int cnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1452,12 +1376,8 @@
 	return (scg_cmd(scgp));
 }
 
-EXPORT int
-write_g1(scgp, bp, addr, cnt)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
+int
+write_g1(SCSI *scgp, caddr_t bp, long addr, int cnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1481,9 +1401,8 @@
 }
 
 #ifdef	used
-LOCAL void
-Xrequest_sense(scgp)
-	SCSI	*scgp;
+static void
+Xrequest_sense(SCSI *scgp)
 {
 	char	sense_buf[32];
 	struct	scg_cmd ocmd;
@@ -1522,14 +1441,10 @@
 }
 #endif
 
-LOCAL int
-read_retry(scgp, bp, addr, cnt, rfunc, rp)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	long	cnt;
-	int	(*rfunc)__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
-	rparm_t	*rp;
+static int
+read_retry(SCSI *scgp, caddr_t bp, long addr, long cnt, 
+			  int (*rfunc)(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt), 
+			  rparm_t *rp)
 {
 /*	int	secsize = scgp->cap->c_bsize;*/
 	int	secsize = rp->secsize;
@@ -1625,13 +1540,11 @@
 	return (0);
 }
 
-LOCAL void
-read_generic(scgp, parmp, rfunc, rp, dfunc)
-	SCSI	*scgp;
-	parm_t	*parmp;
-	int	(*rfunc)__PR((SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt));
-	rparm_t	*rp;
-	int	(*dfunc)__PR((rparm_t *rp, caddr_t bp, long addr, int cnt));
+static void
+read_generic(SCSI *scgp, parm_t *parmp, 
+				 int (*rfunc)(SCSI *scgp, rparm_t *rp, caddr_t bp, long addr, int cnt),
+				 rparm_t *rp,
+				 int (*dfunc)(rparm_t *rp, caddr_t bp, long addr, int cnt))
 {
 	char	filename[512];
 	char	*defname = NULL;
@@ -1820,10 +1733,8 @@
 	print_bad();
 }
 
-LOCAL void
-write_disk(scgp, parmp)
-	SCSI	*scgp;
-	parm_t	*parmp;
+static void
+write_disk(SCSI *scgp, parm_t *parmp)
 {
 	char	filename[512];
 	char	*defname = "disk.out";
@@ -1919,17 +1830,16 @@
 		(double)((addr - start)/(1024.0/scgp->cap->c_bsize)) / (0.001*msec));
 }
 
-LOCAL int
-choice(n)
-	int	n;
+static int
+choice(int n)
 {
 #if	defined(HAVE_DRAND48)
-	extern	double	drand48 __PR((void));
+	extern	double	drand48(void);
 
 	return (drand48() * n);
 #else
 #	if	defined(HAVE_RAND)
-	extern	int	rand __PR((void));
+	extern	int	rand(void);
 
 	return (rand() % n);
 #	else
@@ -1938,9 +1848,8 @@
 #endif
 }
 
-LOCAL void
-ra(scgp)
-	SCSI	*scgp;
+static void
+ra(SCSI *scgp)
 {
 /*	char	filename[512];*/
 	FILE	*f;
@@ -1967,14 +1876,8 @@
 				(cdb)->count[1] = ((len) >> 8L) & 0xFF,\
 				(cdb)->count[2] = (len) & 0xFF)
 
-EXPORT int
-read_da(scgp, bp, addr, cnt, framesize, subcode)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
-	int	framesize;
-	int	subcode;
+int
+read_da(SCSI *scgp, caddr_t bp, long addr, int cnt, int framesize, int subcode)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -1998,15 +1901,9 @@
 	return (scg_cmd(scgp));
 }
 
-EXPORT int
-read_cd(scgp, bp, addr, cnt, framesize, data, subch)
-	SCSI	*scgp;
-	caddr_t	bp;
-	long	addr;
-	int	cnt;
-	int	framesize;
-	int	data;
-	int	subch;
+int
+read_cd(SCSI *scgp, caddr_t bp, long addr, int cnt, int framesize, int data, 
+		  int subch)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -2030,11 +1927,8 @@
 	return (scg_cmd(scgp));
 }
 
-LOCAL void
-oldmode(scgp, errp, retrp)
-	SCSI	*scgp;
-	int	*errp;
-	int	*retrp;
+static void
+oldmode(SCSI *scgp, int *errp, int *retrp)
 {
 	Uchar	mode[0x100];
 	Uchar	cmode[0x100];
@@ -2070,11 +1964,8 @@
 		*retrp = i;
 }
 
-LOCAL void
-domode(scgp, err, retr)
-	SCSI	*scgp;
-	int	err;
-	int	retr;
+static void
+domode(SCSI *scgp, int err, int retr)
 {
 	Uchar	mode[0x100];
 	Uchar	cmode[0x100];
@@ -2131,19 +2022,16 @@
 
 
 /*--------------------------------------------------------------------------*/
-LOCAL	void	qpto96		__PR((Uchar *sub, Uchar *subq, int dop));
+static	void	qpto96(Uchar *sub, Uchar *subq, int dop);
 /*EXPORT	void	qpto96		__PR((Uchar *sub, Uchar *subq, int dop));*/
 /*
  * Q-Sub auf 96 Bytes blähen und P-Sub addieren
  *
  * OUT: sub, IN: subqptr
  */
-LOCAL void
+static void
 /*EXPORT void*/
-qpto96(sub, subqptr, dop)
-	Uchar	*sub;
-	Uchar	*subqptr;
-	int	dop;
+qpto96(Uchar *sub, Uchar *subqptr, int dop)
 {
 	Uchar	tmp[16];
 	Uchar	*p;
@@ -2200,9 +2088,8 @@
 
 /*--------------------------------------------------------------------------*/
 
-LOCAL void
-ovtime(scgp)
-	SCSI	*scgp;
+static void
+ovtime(SCSI *scgp)
 {
 	register int	i;
 
@@ -2275,9 +2162,8 @@
 int	nbad;
 int	maxbad;
 
-LOCAL void
-add_bad(addr)
-	long	addr;
+static void
+add_bad(long addr)
 {
 	if (maxbad == 0) {
 		maxbad = BAD_INC;
@@ -2294,7 +2180,7 @@
 	badsecs[nbad++] = addr;
 }
 
-LOCAL void
+static void
 print_bad()
 {
 	int	i;

Modified: nonameyet/branches/cleanup/rscsi/rscsi.c
===================================================================
--- nonameyet/branches/cleanup/rscsi/rscsi.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/rscsi/rscsi.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -72,49 +72,48 @@
 #include <netdb.h>
 #endif
 
-EXPORT	int	main		__PR((int argc, char **argv));
 #ifdef	USE_REMOTE
-LOCAL	void	checkuser	__PR((void));
-LOCAL	char	*getpeer	__PR((void));
-LOCAL	BOOL	checktarget	__PR((void));
-LOCAL	BOOL	strmatch	__PR((char *str, char *pat));
-LOCAL	void	dorscsi		__PR((void));
-LOCAL	void	scsiversion	__PR((void));
-LOCAL	void	openscsi	__PR((void));
-LOCAL	void	closescsi	__PR((void));
-LOCAL	void	maxdma		__PR((void));
-LOCAL	void	getbuf		__PR((void));
-LOCAL	void	freebuf		__PR((void));
-LOCAL	void	havebus		__PR((void));
-LOCAL	void	scsifileno	__PR((void));
-LOCAL	void	initiator_id	__PR((void));
-LOCAL	void	isatapi		__PR((void));
-LOCAL	void	scsireset	__PR((void));
-LOCAL	void	sendcmd		__PR((void));
+static	void	checkuser(void);
+static	char	*getpeer(void);
+static	BOOL	checktarget(void);
+static	BOOL	strmatch(char *str, char *pat);
+static	void	dorscsi(void);
+static	void	scsiversion(void);
+static	void	openscsi(void);
+static	void	closescsi(void);
+static	void	maxdma(void);
+static	void	getbuf(void);
+static	void	freebuf(void);
+static	void	havebus(void);
+static	void	scsifileno(void);
+static	void	initiator_id(void);
+static	void	isatapi(void);
+static	void	scsireset(void);
+static	void	sendcmd(void);
 
-LOCAL	int	fillrdbuf	__PR((void));
-LOCAL	int	readchar	__PR((char *cp));
+static	int	fillrdbuf(void);
+static	int	readchar(char *cp);
 
-LOCAL	void	readbuf		__PR((char *buf, int n));
-LOCAL	void	voidarg		__PR((int n));
-LOCAL	void	readarg		__PR((char *buf, int n));
-LOCAL	char *	preparebuffer	__PR((int size));
-LOCAL	int	checkscsi	__PR((char *decive));
-LOCAL	void	rscsirespond	__PR((int ret, int err));
-LOCAL	void	rscsireply	__PR((int ret));
-LOCAL	void	rscsierror	__PR((int err, char *str, char *xstr));
+static	void	readbuf(char *buf, int n);
+static	void	voidarg(int n);
+static	void	readarg(char *buf, int n);
+static	char *preparebuffer(int size);
+static	int	checkscsi(char *decive);
+static	void	rscsirespond(int ret, int err);
+static	void	rscsireply(int ret);
+static	void	rscsierror(int err, char *str, char *xstr);
 
 #define	CMD_SIZE	80
 
-LOCAL	SCSI	*scsi_ptr = NULL;
-LOCAL	char	*Sbuf;
-LOCAL	long	Sbufsize;
+static	SCSI	*scsi_ptr = NULL;
+static	char	*Sbuf;
+static	long	Sbufsize;
 
-LOCAL	char	*username;
-LOCAL	char	*peername;
+static	char	*username;
+static	char	*peername;
 
-LOCAL	char	*debug_name;
-LOCAL	FILE	*debug_file;
+static	char	*debug_name;
+static	FILE	*debug_file;
 
 #define	DEBUG(fmt)		if (debug_file) js_fprintf(debug_file, fmt)
 #define	DEBUG1(fmt,a)		if (debug_file) js_fprintf(debug_file, fmt, a)
@@ -125,10 +124,8 @@
 #define	DEBUG6(fmt,a1,a2,a3,a4,a5,a6)	if (debug_file) js_fprintf(debug_file, fmt, a1, a2, a3, a4, a5, a6)
 #endif	/* USE_REMOTE */
 
-EXPORT int
-main(argc, argv)
-	int	argc;
-	char	**argv;
+int
+main(int argc, char *argv[])
 {
 	save_args(argc, argv);
 #ifndef	USE_REMOTE
@@ -209,7 +206,7 @@
 }
 
 #ifdef	USE_REMOTE
-LOCAL void
+static void
 checkuser()
 {
 	uid_t	uid = getuid();
@@ -248,7 +245,7 @@
 #endif
 #endif
 
-LOCAL char *
+static char *
 getpeer()
 {
 #ifdef	HAVE_GETNAMEINFO
@@ -332,7 +329,7 @@
 	}
 }
 
-LOCAL BOOL
+static BOOL
 checktarget()
 {
 	char	*target;
@@ -395,10 +392,8 @@
 	return (FALSE);
 }
 
-LOCAL BOOL
-strmatch(str, pat)
-	char	*str;
-	char	*pat;
+static BOOL
+strmatch(char *str, char *pat)
 {
 	int	*aux;
 	int	*state;
@@ -433,7 +428,7 @@
 	return (FALSE);
 }
 
-LOCAL void
+static void
 dorscsi()
 {
 	char	c;
@@ -489,7 +484,7 @@
 	exit(0);
 }
 
-LOCAL void
+static void
 scsiversion()
 {
 	int	ret;
@@ -509,7 +504,7 @@
 	_nixwrite(STDOUT_FILENO, str, ret);
 }
 
-LOCAL void
+static void
 openscsi()
 {
 	char	device[CMD_SIZE];
@@ -564,7 +559,7 @@
 	(void) _nixwrite(STDOUT_FILENO, rbuf, ret);
 }
 
-LOCAL void
+static void
 closescsi()
 {
 	int	ret;
@@ -577,7 +572,7 @@
 	scsi_ptr = NULL;
 }
 
-LOCAL void
+static void
 maxdma()
 {
 	int	ret;
@@ -593,7 +588,7 @@
 	rscsirespond(ret, geterrno());
 }
 
-LOCAL void
+static void
 getbuf()
 {
 	int	ret = 0;
@@ -611,7 +606,7 @@
 	rscsirespond(ret, geterrno());
 }
 
-LOCAL void
+static void
 freebuf()
 {
 	int	ret = 0;
@@ -628,7 +623,7 @@
 	rscsirespond(ret, geterrno());
 }
 
-LOCAL void
+static void
 havebus()
 {
 	int	ret;
@@ -646,7 +641,7 @@
 	rscsirespond(ret, geterrno());
 }
 
-LOCAL void
+static void
 scsifileno()
 {
 	int	ret;
@@ -676,7 +671,7 @@
 		rscsireply(ret);
 }
 
-LOCAL void
+static void
 initiator_id()
 {
 	int	ret;
@@ -696,7 +691,7 @@
 		rscsireply(ret);
 }
 
-LOCAL void
+static void
 isatapi()
 {
 	int	ret;
@@ -716,7 +711,7 @@
 		rscsireply(ret);
 }
 
-LOCAL void
+static void
 scsireset()
 {
 	int	ret;
@@ -732,7 +727,7 @@
 	rscsirespond(ret, geterrno());
 }
 
-LOCAL void
+static void
 sendcmd()
 {
 	register struct	scg_cmd	*scmd;
@@ -854,11 +849,11 @@
 }
 
 #define	READB_SIZE	128
-LOCAL	char		readb[READB_SIZE];
-LOCAL	char		*readbptr;
-LOCAL	int		readbcnt;
+static	char		readb[READB_SIZE];
+static	char		*readbptr;
+static	int		readbcnt;
 
-LOCAL int
+static int
 fillrdbuf()
 {
 	readbptr = readb;
@@ -866,9 +861,8 @@
 	return (readbcnt = _niread(STDIN_FILENO, readb, READB_SIZE));
 }
 
-LOCAL int
-readchar(cp)
-	char	*cp;
+static int
+readchar(char *cp)
 {
 	if (--readbcnt < 0) {
 		if (fillrdbuf() <= 0)
@@ -879,10 +873,8 @@
 	return (1);
 }
 
-LOCAL void
-readbuf(buf, n)
-	register char	*buf;
-	register int	n;
+static void
+readbuf(register char *buf, register int n)
 {
 	register int	i = 0;
 	register int	amt;
@@ -907,9 +899,8 @@
 	}
 }
 
-LOCAL void
-voidarg(n)
-	register int	n;
+static void
+voidarg(register int n)
 {
 	register int	i;
 	register int	amt;
@@ -923,10 +914,8 @@
 	}
 }
 
-LOCAL void
-readarg(buf, n)
-	char	*buf;
-	int	n;
+static void
+readarg(char *buf, int n)
 {
 	int	i;
 
@@ -939,9 +928,8 @@
 	buf[i] = '\0';
 }
 
-LOCAL char *
-preparebuffer(size)
-	int	size;
+static char *
+preparebuffer(int size)
 {
 	Sbufsize = size;
 	if ((Sbuf = scg_getbuf(scsi_ptr, Sbufsize)) == NULL) {
@@ -965,9 +953,8 @@
 	return (Sbuf);
 }
 
-LOCAL int
-checkscsi(device)
-	char	*device;
+static int
+checkscsi(char *device)
 {
 #ifdef	CHECKTAPE
 	if (strncmp(device, "/dev/rst", 8) == 0 ||
@@ -981,10 +968,8 @@
 #endif
 }
 
-LOCAL void
-rscsirespond(ret, err)
-	int	ret;
-	int	err;
+static void
+rscsirespond(int ret, int err)
 {
 	if (ret < 0) {
 		rscsierror(err, errmsgstr(err), NULL);
@@ -993,9 +978,8 @@
 	}
 }
 
-LOCAL void
-rscsireply(ret)
-	int	ret;
+static void
+rscsireply(int ret)
 {
 	char	rbuf[CMD_SIZE];
 
@@ -1004,11 +988,8 @@
 	(void) _nixwrite(STDOUT_FILENO, rbuf, strlen(rbuf));
 }
 
-LOCAL void
-rscsierror(err, str, xstr)
-	int	err;
-	char	*str;
-	char	*xstr;
+static void
+rscsierror(int err, char *str, char *xstr)
 {
 	char	rbuf[1600];
 	int	xlen = 0;

Modified: nonameyet/branches/cleanup/scgcheck/dmaresid.c
===================================================================
--- nonameyet/branches/cleanup/scgcheck/dmaresid.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/scgcheck/dmaresid.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -51,9 +51,9 @@
 #include "cdrecord.h"
 #include "scgcheck.h"
 
-EXPORT	void	dmaresid	__PR((SCSI *scgp));
-LOCAL	int	xtinquiry	__PR((SCSI *scgp, int cnt, int dmacnt));
-LOCAL	int	tinquiry	__PR((SCSI *scgp, caddr_t bp, int cnt, int dmacnt));
+void	dmaresid(SCSI *scgp);
+static	int	xtinquiry(SCSI *scgp, int cnt, int dmacnt);
+static	int	tinquiry(SCSI *scgp, caddr_t bp, int cnt, int dmacnt);
 
 
 extern	char	*buf;			/* The transfer buffer */
@@ -62,9 +62,8 @@
 extern	FILE	*logfile;
 extern	char	unavail[];
 
-EXPORT void
-dmaresid(scgp)
-	SCSI	*scgp;
+void
+dmaresid(SCSI *scgp)
 {
 	char	abuf[2];
 	int	cnt = sizeof (struct scsi_inquiry);
@@ -196,11 +195,8 @@
 	}
 }
 
-LOCAL int
-xtinquiry(scgp, cnt, dmacnt)
-	SCSI	*scgp;
-	int	cnt;
-	int	dmacnt;
+static int
+xtinquiry(SCSI *scgp, int cnt, int dmacnt)
 {
 	Uchar	ibuf[1024];
 	struct scsi_inquiry	*ip;
@@ -240,12 +236,8 @@
 	return (maxcnt);
 }
 
-LOCAL int
-tinquiry(scgp, bp, cnt, dmacnt)
-	SCSI	*scgp;
-	caddr_t	bp;
-	int	cnt;
-	int	dmacnt;
+static int
+tinquiry(SCSI *scgp, caddr_t bp, int cnt, int dmacnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 

Modified: nonameyet/branches/cleanup/scgcheck/scgcheck.c
===================================================================
--- nonameyet/branches/cleanup/scgcheck/scgcheck.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/scgcheck/scgcheck.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -52,16 +52,15 @@
 #include "cdrecord.h"
 #include "scgcheck.h"
 
-LOCAL	void	usage		__PR((int ret));
-EXPORT	int	main		__PR((int ac, char *av[]));
-LOCAL	SCSI	*doopen		__PR((char *dev));
-LOCAL	void	checkversion	__PR((SCSI *scgp));
-LOCAL	void	getbuf		__PR((SCSI *scgp));
-EXPORT	void	flushit		__PR((void));
-EXPORT	int	countopen	__PR((void));
+static	void	usage(int ret);
+static	SCSI	*doopen(char *dev);
+static	void	checkversion(SCSI *scgp);
+static	void	getbuf(SCSI *scgp);
+void	flushit(void);
+int	countopen(void);
 
 
-	char	*dev;
+char	*dev;
 int		debug;		/* print debug messages */
 int		kdebug;		/* kernel debug messages */
 int		scsi_verbose;	/* SCSI verbose flag */
@@ -81,9 +80,8 @@
 #define	BUF_SIZE	(126*1024)
 #define	MAX_BUF_SIZE	(16*1024*1024)
 
-LOCAL void
-usage(ret)
-	int	ret;
+static void
+usage(int ret)
 {
 	error("Usage:\tscgcheck [options]\n");
 	error("Options:\n");
@@ -102,10 +100,8 @@
 
 char	opts[]   = "debug#,d+,kdebug#,kd#,timeout#,verbose+,v+,Verbose+,V+,silent,s,x+,xd#,help,h,version,dev*,f*";
 
-EXPORT int
-main(ac, av)
-	int	ac;
-	char	*av[];
+int
+main(int argc, char *argv[])
 {
 	int	cac;
 	char	* const *cav;
@@ -118,10 +114,10 @@
 	BOOL	pversion = FALSE;
 	char	*filename = "check.log";
 
-	save_args(ac, av);
+	save_args(argc, argv);
 
-	cac = --ac;
-	cav = ++av;
+	cac = --argc;
+	cav = ++argv;
 
 	if (getallargs(&cac, &cav, opts,
 			&debug, &debug,
@@ -147,8 +143,8 @@
 	}
 
 	fcount = 0;
-	cac = ac;
-	cav = av;
+	cac = argc;
+	cav = argv;
 
 	while (getfiles(&cac, &cav, opts) > 0) {
 		fcount++;
@@ -392,9 +388,8 @@
 	return (0);
 }
 
-LOCAL SCSI *
-doopen(devname)
-	char	*devname;
+static SCSI *
+doopen(char *devname)
 {
 	SCSI	*scgp;
 	char	errstr[128];
@@ -416,9 +411,8 @@
 	return (scgp);
 }
 
-LOCAL void
-checkversion(scgp)
-	SCSI	*scgp;
+static void
+checkversion(SCSI *scgp)
 {
 	char	*vers;
 	char	*auth;
@@ -469,9 +463,8 @@
 	fprintf(logfile, "Using remote transport code version '%s-%s'\n", auth, vers);
 }
 
-LOCAL void
-getbuf(scgp)
-	SCSI	*scgp;
+static void
+getbuf(SCSI *scgp)
 {
 	bufsize = scg_bufsize(scgp, MAX_BUF_SIZE);
 		printf("Max DMA buffer size: %ld\n", bufsize);
@@ -492,7 +485,7 @@
 		comerr("Cannot get SCSI I/O buffer.\n");
 }
 
-EXPORT void
+void
 flushit()
 {
 	flush();

Modified: nonameyet/branches/cleanup/scgcheck/scgcheck.h
===================================================================
--- nonameyet/branches/cleanup/scgcheck/scgcheck.h	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/scgcheck/scgcheck.h	2006-10-12 19:38:29 UTC (rev 368)
@@ -32,14 +32,14 @@
 /*
  * scgcheck.c
  */
-extern	void	flushit		__PR((void));
+extern	void	flushit(void);
 
 /*
  * sense.c
  */
-extern	void	sensetest	__PR((SCSI *scgp));
+extern	void	sensetest(SCSI *scgp);
 
 /*
  * dmaresid.c
  */
-extern	void	dmaresid	__PR((SCSI *scgp));
+extern	void	dmaresid(SCSI *scgp);

Modified: nonameyet/branches/cleanup/scgcheck/sense.c
===================================================================
--- nonameyet/branches/cleanup/scgcheck/sense.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/scgcheck/sense.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -57,17 +57,16 @@
 extern	FILE	*logfile;
 extern	char	unavail[];
 
-LOCAL	BOOL	inq_nofail = FALSE;
+static	BOOL	inq_nofail = FALSE;
 
 
-EXPORT	void	sensetest	__PR((SCSI *scgp));
-LOCAL	int	sensecount	__PR((SCSI *scgp, int sensecnt));
-LOCAL	int	badinquiry	__PR((SCSI *scgp, caddr_t bp, int cnt, int sensecnt));
-LOCAL	int	bad_unit_ready	__PR((SCSI *scgp, int sensecnt));
+void	sensetest(SCSI *scgp);
+static	int	sensecount(SCSI *scgp, int sensecnt);
+static	int	badinquiry(SCSI *scgp, caddr_t bp, int cnt, int sensecnt);
+static	int	bad_unit_ready(SCSI *scgp, int sensecnt);
 
-EXPORT void
-sensetest(scgp)
-	SCSI	*scgp;
+void
+sensetest(SCSI *scgp)
 {
 	char	abuf[2];
 	int	ret;
@@ -189,10 +188,8 @@
 	}
 }
 
-LOCAL int
-sensecount(scgp, sensecnt)
-	SCSI	*scgp;
-	int	sensecnt;
+static int
+sensecount(SCSI *scgp, int sensecnt)
 {
 	int	maxcnt;
 	int	i;
@@ -250,12 +247,8 @@
 	return (maxcnt);
 }
 
-LOCAL int
-badinquiry(scgp, bp, cnt, sensecnt)
-	SCSI	*scgp;
-	caddr_t	bp;
-	int	cnt;
-	int	sensecnt;
+static int
+badinquiry(SCSI *scgp, caddr_t bp, int cnt, int sensecnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 
@@ -282,10 +275,8 @@
 	return (0);
 }
 
-LOCAL int
-bad_unit_ready(scgp, sensecnt)
-	SCSI	*scgp;
-	int	sensecnt;
+static int
+bad_unit_ready(SCSI *scgp, int sensecnt)
 {
 	register struct	scg_cmd	*scmd = scgp->scmd;
 

Modified: nonameyet/branches/cleanup/scgskeleton/skel.c
===================================================================
--- nonameyet/branches/cleanup/scgskeleton/skel.c	2006-10-08 20:54:40 UTC (rev 367)
+++ nonameyet/branches/cleanup/scgskeleton/skel.c	2006-10-12 19:38:29 UTC (rev 368)
@@ -63,8 +63,8 @@
 
 char	skel_version[] = "1.1";
 
-extern	BOOL	getlong		__PR((char *, long *, long, long));
-extern	BOOL	getint		__PR((char *, int *, int, int));
+extern	BOOL	getlong(char *, long *, long, long);
+extern	BOOL	getint(char *, int *, int, int);
 
 struct exargs {
 	SCSI	*scgp;
@@ -74,15 +74,14 @@
 	char	oerr[3];
 } exargs;
 
-LOCAL	void	usage		__PR((int ret));
-EXPORT	int	main		__PR((int ac, char **av));
-LOCAL	void	intr		__PR((int sig));
-LOCAL	void	exscsi		__PR((int excode, void *arg));
-LOCAL	void	excdr		__PR((int excode, void *arg));
-LOCAL	int	prstats		__PR((void));
-LOCAL	int	prstats_silent	__PR((void));
-LOCAL	void	doit		__PR((SCSI *scgp));
-LOCAL	void	dofile		__PR((SCSI *scgp, char *filename));
+static	void	usage(int ret);
+static	void	intr(int sig);
+static	void	exscsi(int excode, void *arg);
+static	void	excdr(int excode, void *arg);
+static	int	prstats(void);
+static	int	prstats_silent(void);
+static	void	doit(SCSI *scgp);
+static	void	dofile(SCSI *scgp, char *filename);
 
 
 struct timeval	starttime;
@@ -99,8 +98,8 @@
 int	quiet;
 BOOL	is_suid;
 
-LOCAL void
-usage(ret)
+static void
+usage(int ret)
 	int	ret;
 {
 	error("Usage:\tscgskeleton [options]\n");
@@ -122,10 +121,8 @@
 
 char	opts[]   = "debug#,d+,kdebug#,kd#,timeout#,quiet,q,verbose+,v+,Verbose+,V+,x+,xd#,silent,s,help,h,version,scanbus,dev*,ts&,f*";
 
-EXPORT int
-main(ac, av)
-	int	ac;
-	char	*av[];
+int
+main(int argc, char *argv[])
 {
 	char	*dev = NULL;
 	int	fcount;
@@ -144,10 +141,10 @@
 	SCSI	*scgp;
 	char	*filename = NULL;
 
-	save_args(ac, av);
+	save_args(argc, argv);
 
-	cac = --ac;
-	cav = ++av;
+	cac = --argc;
+	cav = ++argv;
 
 	if (getallargs(&cac, &cav, opts,
 			&debug, &debug,
@@ -176,8 +173,8 @@
 	}
 
 	fcount = 0;
-	cac = ac;
-	cav = av;
+	cac = argc;
+	cav = argv;
 
 	while (getfiles(&cac, &cav, opts) > 0) {
 		fcount++;
@@ -337,9 +334,8 @@
  * XXX da meistens das letzte SCSI Kommando noch laeuft.
  * XXX Eine Loesung waere ein Abort Callback in SCSI *.
  */
-LOCAL void
-intr(sig)
-	int	sig;
+static void
+intr(int sig)
 {
 	didintr++;
 	exsig = sig;
@@ -347,10 +343,8 @@
 }
 
 /* ARGSUSED */
-LOCAL void
-exscsi(excode, arg)
-	int	excode;
-	void	*arg;
+static void
+exscsi(int excode, void *arg)
 {
 	struct exargs	*exp = (struct exargs *)arg;
 		int	i;
@@ -385,10 +379,8 @@
 	}
 }
 
-LOCAL void
-excdr(excode, arg)
-	int	excode;
-	void	*arg;
+static void
+excdr(int excode, void *arg)
 {
 	exscsi(excode, arg);
 
@@ -400,7 +392,7 @@
 /*
  * Return milliseconds since start time.
  */
-LOCAL int
+static int
 prstats()
 {
 	int	sec;
@@ -428,7 +420,7 @@
 /*
  * Return milliseconds since start time, but be silent this time.
  */
-LOCAL int
+static int
 prstats_silent()
 {
 	int	sec;
@@ -452,9 +444,8 @@
 	return (1000*sec + (usec / 1000));
 }
 
-LOCAL void
-doit(scgp)
-	SCSI	*scgp;
+static void
+doit(SCSI *scgp)
 {
 	int	i = 0;
 
@@ -478,10 +469,8 @@
 	}
 }
 
-LOCAL void
-dofile(scgp, filename)
-	SCSI	*scgp;
-	char	*filename;
+static void
+dofile(SCSI *scgp, char *filename)
 {
 }
 




More information about the Debburn-changes mailing list