reading tapes on 386/ix written to SCO's /dev/erct0

Pim Zandbergen pim at cti-software.nl
Fri Oct 19 05:45:08 AEST 1990


I wrote:

>I have these two tapes I want to read on our 386/ix 2.0.2 system.
>But apperently they were written on SCO UNIX using /dev/erct0,
>the error correcting device.

With a bit of experimenting, I solved the problem myself.

This is the program I used.
Usage:
	dd if=/dev/tape bs=256k | skipecc | cpio -i ....


#--------------------------------CUT HERE-------------------------------------
#! /bin/sh
#
# This is a shell archive.  Save this into a file, edit it
# and delete all lines above this comment.  Then give this
# file to sh by executing the command "sh file".  The files
# will be extracted into the current directory owned by
# you with default permissions.
#
# The files contained herein are:
#
# -rw-rw-r--   1 pim      other        196 Oct 18 20:33 skipecc.c
#
echo 'x - skipecc.c'
if test -f skipecc.c; then echo 'shar: not overwriting skipecc.c'; else
sed 's/^X//' << '________This_Is_The_END________' > skipecc.c
X#define	READBYTES	32768
X#define	WRITEBYTES	31744
X
X#include	<stdio.h>
X
Xmain()
X{
X	char	buffer[READBYTES];
X
X	while (fread(buffer, 1, READBYTES, stdin) > 0)
X		fwrite(buffer, 1, WRITEBYTES, stdout);
X}
________This_Is_The_END________
if test `wc -c < skipecc.c` -ne 196; then
	echo 'shar: skipecc.c was damaged during transit (should have been 196 bytes)'
fi
fi		; : end of overwriting check
exit 0
-- 
Pim Zandbergen                          domain : pim at cti-software.nl
CTI Software BV                         uucp   : uunet!mcsun!hp4nl!ctisbv!pim
Laan Copes van Cattenburch 70           phone  : +31 70 3542302
2585 GD The Hague, The Netherlands      fax    : +31 70 3512837



More information about the Comp.unix.xenix.sco mailing list