[Qemu-devel] [PULL V2 01/13] net/colo-compare.c: Remove duplicated code

Jason Wang posted 13 patches 6 years, 1 month ago
Maintainers: Juan Quintela <quintela@redhat.com>, Zhang Chen <zhangckid@gmail.com>, "Dr. David Alan Gilbert" <dgilbert@redhat.com>, Li Zhijian <lizhijian@cn.fujitsu.com>, "Michael S. Tsirkin" <mst@redhat.com>, Jason Wang <jasowang@redhat.com>, Vincenzo Maffione <v.maffione@gmail.com>, Markus Armbruster <armbru@redhat.com>, Luigi Rizzo <rizzo@iet.unipi.it>, Eric Blake <eblake@redhat.com>, Giuseppe Lettieri <g.lettieri@iet.unipi.it>
There is a newer version of this series
[Qemu-devel] [PULL V2 01/13] net/colo-compare.c: Remove duplicated code
Posted by Jason Wang 6 years, 1 month ago
From: Zhang Chen <chen.zhang@intel.com>

Fix duplicated code:
https://bugs.launchpad.net/qemu/+bug/1811499

Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Zhang Chen <chen.zhang@intel.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
 net/colo-compare.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/net/colo-compare.c b/net/colo-compare.c
index 3e515f3..bf10526 100644
--- a/net/colo-compare.c
+++ b/net/colo-compare.c
@@ -294,14 +294,6 @@ static bool colo_mark_tcp_pkt(Packet *ppkt, Packet *spkt,
             return true;
         }
     }
-    if (ppkt->tcp_seq == spkt->tcp_seq && ppkt->seq_end == spkt->seq_end) {
-        if (colo_compare_packet_payload(ppkt, spkt,
-                                        ppkt->header_size, spkt->header_size,
-                                        ppkt->payload_size)) {
-            *mark = COLO_COMPARE_FREE_SECONDARY | COLO_COMPARE_FREE_PRIMARY;
-            return true;
-        }
-    }
 
     /* one part of secondary packet payload still need to be compared */
     if (!after(ppkt->seq_end, spkt->seq_end)) {
-- 
2.5.0