Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2023 Kern Sibbald
+ All rights reserved.
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
rdev->device = dcr->dev->device;
rdcr = new_dcr(jcr, NULL, rdev, SD_READ);
rdcr->spool_fd = dcr->spool_fd;
- block = rdcr->block; /* save block */
- rdcr->block = dcr->block; /* make read and write block the same */
+ block = dcr->block; /* save block */
+ dcr->block = rdcr->block; /* make read and write block the same */
Dmsg1(800, "read/write block size = %d\n", block->buf_len);
lseek(rdcr->spool_fd, 0, SEEK_SET); /* rewind */
despool_elapsed / 3600, despool_elapsed % 3600 / 60, despool_elapsed % 60,
edit_uint64_with_suffix(jcr->dcr->job_spool_size / despool_elapsed, ec1));
- rdcr->block = block; /* reset block */
+ dcr->block = block; /* reset block */
#if defined(HAVE_POSIX_FADVISE) && defined(POSIX_FADV_DONTNEED)
posix_fadvise(rdcr->spool_fd, 0, 0, POSIX_FADV_DONTNEED);
if (block->binbuf <= WRITE_BLKHDR_LENGTH) { /* Does block have data in it? */
return true;
}
+
hlen = sizeof(spool_hdr);
wlen = block->binbuf;
P(dcr->dev->spool_mutex);