rwfile = FDH_FDOPEN(rwFd, ReadWriteOriginal ? "r+" : "r");
if (!rwfile)
ERROR_EXIT(EIO);
- STREAM_SEEK(rwfile, vcp->diskSize, 0); /* Will fail if no vnodes */
+ STREAM_ASEEK(rwfile, vcp->diskSize); /* Will fail if no vnodes */
/* Open the clone volume's index file and seek to beginning */
IH_COPY(clHout, clvp->vnodeIndex[class].handle);
clfileout = FDH_FDOPEN(clFdOut, "a");
if (!clfileout)
ERROR_EXIT(EIO);
- code = STREAM_SEEK(clfileout, vcp->diskSize, 0);
+ code = STREAM_ASEEK(clfileout, vcp->diskSize);
if (code)
ERROR_EXIT(EIO);
clfilein = FDH_FDOPEN(clFdIn, "r");
if (!clfilein)
ERROR_EXIT(EIO);
- STREAM_SEEK(clfilein, vcp->diskSize, 0); /* Will fail if no vnodes */
+ STREAM_ASEEK(clfilein, vcp->diskSize); /* Will fail if no vnodes */
}
/* Initialize list of inodes to nuke */
rwvnode->dataVersion++;
#endif /* DVINC */
rwvnode->cloned = 1;
- code = STREAM_SEEK(rwfile, offset, 0);
+ code = STREAM_ASEEK(rwfile, offset);
if (code == -1)
goto clonefailed;
code = STREAM_WRITE(rwvnode, vcp->diskSize, 1, rwfile);
if (code != 1)
goto clonefailed;
dircloned = 1;
- code = STREAM_SEEK(rwfile, offset + vcp->diskSize, 0);
+ code = STREAM_ASEEK(rwfile, offset + vcp->diskSize);
if (code == -1)
goto clonefailed;
#ifdef DVINC
/* And if the directory was marked clone, unmark it */
if (dircloned) {
rwvnode->cloned = 0;
- if (STREAM_SEEK(rwfile, offset, 0) != -1)
+ if (STREAM_ASEEK(rwfile, offset) != -1)
(void)STREAM_WRITE(rwvnode, vcp->diskSize, 1, rwfile);
}
ERROR_EXIT(EIO);
/* Clean out any junk at end of clone file */
if (reclone) {
- STREAM_SEEK(clfilein, offset, 0);
+ STREAM_ASEEK(clfilein, offset);
while (STREAM_READ(clvnode, vcp->diskSize, 1, clfilein) == 1) {
if (clvnode->type != vNull && VNDISK_GET_INO(clvnode) != 0) {
ci_AddItem(&decHead, VNDISK_GET_INO(clvnode));