Patchwork [06/13] migration: fix off-by-one in buffered_rate_limit

login
register
mail settings
Submitter Juan Quintela
Date Jan. 17, 2013, 1:39 p.m.
Message ID <1358429973-9321-7-git-send-email-quintela@redhat.com>
Download mbox | patch
Permalink /patch/213289/
State New
Headers show

Comments

Juan Quintela - Jan. 17, 2013, 1:39 p.m.
From: Paolo Bonzini <pbonzini@redhat.com>

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Reviewed-by: Reviewed-by: Eric Blake <eblake@redhat.com>
---
 migration.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/migration.c b/migration.c
index 5513dde..380f3cb 100644
--- a/migration.c
+++ b/migration.c
@@ -632,7 +632,7 @@  static int buffered_rate_limit(void *opaque)
         return ret;
     }

-    if (s->bytes_xfer > s->xfer_limit) {
+    if (s->bytes_xfer >= s->xfer_limit) {
         return 1;
     }