
/*
 *	Function	CopyFile
 *	Programmer	N.d'Alterio
 *	Date		05/05/96
 *
 *  Synopsis:	Copy contents of one file to another, both files
 *		should be open.
 *
 *  Arguments:	in_fh			Input file pointer
 *		out_fh			Output file pointer
 *
 *  Returns:	None
 *
 *  Variables:	ch			Character buffer
 * 
 *  Functions:	FGetC			Get char (ADOS)
 *		FPutC			Put char (ADOS)
 *
 *  $Id: CopyFile.c 1.2 1996/05/10 22:21:02 nagd Exp $
 *
 */

#include <proto/dos.h>

void CopyFile( BPTR in_fh, BPTR out_fh )

{ 
               
  long ch;

  while ( ( ch = FGetC( in_fh ) ) != -1 ) FPutC( out_fh, ch );
 
  return;

}   /* end function CopyFile */

/*========================================================================*
                            END FUNCTION CopyFile
 *========================================================================*/

