@@ -124,7 +124,7 @@ static PyObject *get_hwaddress(PyObject *self __unused, PyObject *args)
124124 const char * devname ;
125125 char hwaddr [20 ];
126126
127- if (!PyArg_ParseTuple (args , "s* " , & devname ))
127+ if (!PyArg_ParseTuple (args , "s" , & devname ))
128128 return NULL ;
129129
130130 /* Setup our request structure. */
@@ -166,7 +166,7 @@ static PyObject *get_ipaddress(PyObject *self __unused, PyObject *args)
166166 const char * devname ;
167167 char ipaddr [20 ];
168168
169- if (!PyArg_ParseTuple (args , "s* " , & devname ))
169+ if (!PyArg_ParseTuple (args , "s" , & devname ))
170170 return NULL ;
171171
172172 /* Setup our request structure. */
@@ -298,7 +298,7 @@ static PyObject *get_flags (PyObject *self __unused, PyObject *args)
298298 const char * devname ;
299299 int fd , err ;
300300
301- if (!PyArg_ParseTuple (args , "s* " , & devname ))
301+ if (!PyArg_ParseTuple (args , "s" , & devname ))
302302 return NULL ;
303303
304304 /* Setup our request structure. */
@@ -331,7 +331,7 @@ static PyObject *get_netmask (PyObject *self __unused, PyObject *args)
331331 const char * devname ;
332332 char netmask [20 ];
333333
334- if (!PyArg_ParseTuple (args , "s* " , & devname ))
334+ if (!PyArg_ParseTuple (args , "s" , & devname ))
335335 return NULL ;
336336
337337 /* Setup our request structure. */
@@ -371,7 +371,7 @@ static PyObject *get_broadcast(PyObject *self __unused, PyObject *args)
371371 const char * devname ;
372372 char broadcast [20 ];
373373
374- if (!PyArg_ParseTuple (args , "s* " , & devname ))
374+ if (!PyArg_ParseTuple (args , "s" , & devname ))
375375 return NULL ;
376376
377377 /* Setup our request structure. */
@@ -412,7 +412,7 @@ static PyObject *get_module(PyObject *self __unused, PyObject *args)
412412 char buf [2048 ];
413413 const char * devname ;
414414
415- if (!PyArg_ParseTuple (args , "s* " , & devname ))
415+ if (!PyArg_ParseTuple (args , "s" , & devname ))
416416 return NULL ;
417417
418418 /* Setup our control structures. */
@@ -482,7 +482,7 @@ static PyObject *get_businfo(PyObject *self __unused, PyObject *args)
482482 char buf [1024 ];
483483 const char * devname ;
484484
485- if (!PyArg_ParseTuple (args , "s* " , & devname ))
485+ if (!PyArg_ParseTuple (args , "s" , & devname ))
486486 return NULL ;
487487
488488 /* Setup our control structures. */
@@ -548,7 +548,7 @@ static int get_dev_value(int cmd, PyObject *args, void *value)
548548 const char * devname ;
549549 int err = -1 ;
550550
551- if (PyArg_ParseTuple (args , "s* " , & devname ))
551+ if (PyArg_ParseTuple (args , "s" , & devname ))
552552 err = send_command (cmd , devname , value );
553553
554554 return err ;
@@ -570,7 +570,7 @@ static int dev_set_int_value(int cmd, PyObject *args)
570570 struct ethtool_value eval ;
571571 const char * devname ;
572572
573- if (!PyArg_ParseTuple (args , "s*i " , & devname , & eval .data ))
573+ if (!PyArg_ParseTuple (args , "si " , & devname , & eval .data ))
574574 return -1 ;
575575
576576 return send_command (cmd , devname , & eval );
@@ -755,7 +755,7 @@ static PyObject *set_coalesce(PyObject *self __unused, PyObject *args)
755755 const char * devname ;
756756 PyObject * dict ;
757757
758- if (!PyArg_ParseTuple (args , "s*O " , & devname , & dict ))
758+ if (!PyArg_ParseTuple (args , "sO " , & devname , & dict ))
759759 return NULL ;
760760
761761 if (struct_desc_from_dict (ethtool_coalesce_desc , & coal , dict ) != 0 )
@@ -795,7 +795,7 @@ static PyObject *set_ringparam(PyObject *self __unused, PyObject *args)
795795 const char * devname ;
796796 PyObject * dict ;
797797
798- if (!PyArg_ParseTuple (args , "s*O " , & devname , & dict ))
798+ if (!PyArg_ParseTuple (args , "sO " , & devname , & dict ))
799799 return NULL ;
800800
801801 if (struct_desc_from_dict (ethtool_ringparam_desc , & ring , dict ) != 0 )
0 commit comments