{
int ret;
int count = 0;
- uint64_t effective_size;
+ uint64_t effective_size = 0;
ceph_assert(size % truncbdy == 0);
lp = &oplog[i];
if ((closeopen = lp->operation < 0))
lp->operation = ~ lp->operation;
-
+
switch (lp->operation) {
case OP_MAPREAD:
prt("MAPREAD 0x%x thru 0x%x\t(0x%x bytes)",
ret = lseek(fd, (off_t)0, SEEK_SET);
if (ret == (off_t)-1)
prterr("save_buffer: lseek 0");
-
+
byteswritten = write(fd, buffer, (size_t)bufferlength);
if (byteswritten != bufferlength) {
if (byteswritten == -1)
report_failure(int status)
{
logdump();
-
+
if (fsxgoodfd) {
if (good_buf) {
save_buffer(good_buf, file_size, fsxgoodfd);
return;
/*
* we landed in the last page of the file
- * test to make sure the VM system provided 0's
+ * test to make sure the VM system provided 0's
* beyond the true end of the file mapping
* (as required by mmap def in 1996 posix 1003.1)
*/
gendata(char *original_buf, char *good_buf, unsigned offset, unsigned size)
{
while (size--) {
- good_buf[offset] = testcalls % 256;
+ good_buf[offset] = testcalls % 256;
if (offset % 2)
good_buf[offset] += original_buf[offset];
offset++;