- off=`get_offset "$image" $GZHDR1`
- [ "$?" != "0" ] && off="-1"
- if [ "$off" -eq "-1" ]; then
- off=`get_offset "$image" $GZHDR2`
- [ "$?" != "0" ] && off="-1"
- fi
- if [ "$off" -eq "0" ]; then
- zcat < "$image"
- return
- elif [ "$off" -ne "-1" ]; then
- (dd ibs="$off" skip=1 count=0 && dd bs=512k) < "$image" 2>/dev/null | zcat 2>/dev/null
- return
- fi