seekip=fseek(fp,-TBLOCK,SEEK_CUR);
if(seekip==0)
{
if(fwrite((dblock.dummy),TBLOCK,1,fp)!=1)
{
printf(″Can not read the %s!n″,argv[2]);
break;
}
fflush(fp);
}
}
sscanf(dblock.dbuf.size,″%12o″,&filesize);
sscanf(dblock,dbuf.chksum,″%6o″,&sum_v);
sum_v=sum_v-sum-0400-compc;
if(filesize>0&&(dblock.dbuf.linkflag==0x00|| dbloc
k.dbuf.chksum[0]==0x33))
{
mvblock=(filesize-1)/TBLOCK+1;
seekip=fseek(fp,(long)mvblock*TBLOCK,SEEK
_CUR);
}
seekip=fseek(fp,0L,SEEK_CUR);
if(dblock.dbuf.linkflag==″1″)
printf(″%snttnormal linked to %sttcompress=[%c]tsum_v=%on″,
dblock.dbuf.name,dblock.dbuf.linkname,dblock.dbuf.
compid,sum-v);
else if (dblock.dbuf.linkflag==″2″)
printf(″%snttsymbolic linked to %stcompress=[%c]tsum_v=%on,
″dblock.dbuf.name,dblock.dbuf.linkname,dblock.dbuf.
compid,sum_v);
else
printf(″%snt %8d byte-->%6d tape_blockstcompress=[%c]tsum_v=%on″,dblock.dbuf.name,filesize,mvblock,dblock.dbuf.cmpid,sum_v);
}
printf(″Total=%dKn″,ftell(fp)/1024);
fclose(fp);
}
推荐阅读
- tar解压
- 用终端打印机打印Unix文件
- Unix系统管理员安全手册
- 在Unix系统中利用程序实现Kill命令
- 提高unixware文件系统性能
- unix下的动态链接库
- UNIX下发送屏幕信息
- UnixWare 7 与 OpenServer
- sco unix5.05系统intel pro100+网卡安装心得
- 如何备份UNIX系统