> I believe this is quite portable:
   >
   >    dd bs=1 skip=257 count=5 if=/dev/tape of=/some/tmp/file
   >    if test `cat /some/tmp/file` = ustar ; then
   >      : This is a tar file.
   >    fi

   But wait...  You just threw away the first 257 bytes from stdin. Now
   what are you going to put into stdout for tar to read?

Err, rewind to the beginning of the file? ;-)

Ben

Reply via email to