From f3a4c64e3cb35bcc55b9282cf04c79bbd07942d4 Mon Sep 17 00:00:00 2001
From: Pierre LALET <pierre.lalet@cea.fr>
Date: Mon, 25 Jan 2016 17:57:54 +0100
Subject: [PATCH] Fix for Python 2.5 (cannot mix keyword arguments and **kargs)

---
 scapy/plist.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/scapy/plist.py b/scapy/plist.py
index c741ecb9..df8ba494 100644
--- a/scapy/plist.py
+++ b/scapy/plist.py
@@ -212,9 +212,11 @@ lfilter: truth function to apply to each packet to decide whether it will be dis
             kargs = MATPLOTLIB_DEFAULT_PLOT_KARGS
 
         if plot_xy:
-            lines = [plt.plot(*zip(*pl), label=k, **kargs) for k, pl in d.iteritems()]
+            lines = [plt.plot(*zip(*pl), **dict(kargs, label=k))
+                     for k, pl in d.iteritems()]
         else:
-            lines = [plt.plot(pl, label=k, **kargs) for k, pl in d.iteritems()]
+            lines = [plt.plot(pl, **dict(kargs, label=k))
+                     for k, pl in d.iteritems()]
         plt.legend(loc="center right", bbox_to_anchor=(1.5, 0.5))
 
         # Call show() if matplotlib is not inlined
-- 
GitLab