diff options
author | Kevin Wolf <kwolf@redhat.com> | 2020-02-14 21:08:07 +0100 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2020-02-18 10:53:56 +0100 |
commit | d71e65ec1d08849a4e62a778ed4ea732621cea26 (patch) | |
tree | d06b05fff95cd21b3f46a00ba1d07f00868d0427 /block/commit.c | |
parent | 248e3ffb66c27cf95623f965b61b0eb97a607441 (diff) | |
download | qemu-d71e65ec1d08849a4e62a778ed4ea732621cea26.zip qemu-d71e65ec1d08849a4e62a778ed4ea732621cea26.tar.gz qemu-d71e65ec1d08849a4e62a778ed4ea732621cea26.tar.bz2 |
commit: Remove unused bytes_written
The bytes_written variable is only ever written to, it serves no
purpose. This has actually been the case since the commit job was first
introduced in commit 747ff602636.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20200214200812.28180-3-kwolf@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/commit.c')
-rw-r--r-- | block/commit.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/block/commit.c b/block/commit.c index 23c90b3..cce898a 100644 --- a/block/commit.c +++ b/block/commit.c @@ -140,7 +140,6 @@ static int coroutine_fn commit_run(Job *job, Error **errp) int ret = 0; int64_t n = 0; /* bytes */ void *buf = NULL; - int bytes_written = 0; int64_t len, base_len; ret = len = blk_getlength(s->top); @@ -180,7 +179,6 @@ static int coroutine_fn commit_run(Job *job, Error **errp) trace_commit_one_iteration(s, offset, n, ret); if (copy) { ret = commit_populate(s->top, s->base, offset, n, buf); - bytes_written += n; } if (ret < 0) { BlockErrorAction action = |