Skip to content

Commit 9779a0b

Browse files
PEP 7hroncok
authored andcommitted
Inline comments after 2 spaces
1 parent c1e934e commit 9779a0b

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

python-ethtool/etherinfo.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ PyObject * get_etherinfo_address(PyEtherInfo *self, nlQuery query)
273273
}
274274

275275
/* Retrieve all address information */
276-
addrlist = PyList_New(0); /* The list where to put the address object */
276+
addrlist = PyList_New(0); /* The list where to put the address object */
277277
assert(addrlist);
278278

279279
/* Loop through all configured addresses */

python-ethtool/etherinfo.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#ifndef _ETHERINFO_H
1818
#define _ETHERINFO_H
1919

20-
typedef enum {NLQRY_ADDR4, NLQRY_ADDR6} nlQuery; /**< Supported query types in the etherinfo code */
20+
typedef enum {NLQRY_ADDR4, NLQRY_ADDR6} nlQuery; /**< Supported query types in the etherinfo code */
2121

2222
int get_etherinfo_link(PyEtherInfo *data);
2323
PyObject * get_etherinfo_address(PyEtherInfo *self, nlQuery query);

python-ethtool/ethtool-copy.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,6 +368,6 @@ struct ethtool_stats {
368368
#define WAKE_BCAST (1 << 3)
369369
#define WAKE_ARP (1 << 4)
370370
#define WAKE_MAGIC (1 << 5)
371-
#define WAKE_MAGICSECURE (1 << 6) /* only meaningful if WAKE_MAGIC */
371+
#define WAKE_MAGICSECURE (1 << 6) /* only meaningful if WAKE_MAGIC */
372372

373373
#endif /* _LINUX_ETHTOOL_H */

python-ethtool/ethtool.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ typedef __uint16_t u16;
4949
typedef __uint8_t u8;
5050

5151
#include "ethtool-copy.h"
52-
#include <linux/sockios.h> /* for SIOCETHTOOL */
52+
#include <linux/sockios.h> /* for SIOCETHTOOL */
5353

5454
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
5555

@@ -105,9 +105,9 @@ static PyObject *get_devices(PyObject *self __unused, PyObject *args __unused)
105105
/* find colon */
106106
while (*end && *end != ':')
107107
end++;
108-
*end = 0; /* terminate where colon was */
108+
*end = 0; /* terminate where colon was */
109109
while (*name == ' ')
110-
name++; /* skip over leading whitespace if any */
110+
name++; /* skip over leading whitespace if any */
111111

112112
str = PyStr_FromString(name);
113113
PyList_Append(list, str);
@@ -223,12 +223,12 @@ static PyObject *get_interfaces_info(PyObject *self __unused, PyObject *args) {
223223

224224
/* Parse input arguments if we got them */
225225
if (inargs != NULL) {
226-
if (PyStr_Check(inargs)) { /* Input argument is just a string */
226+
if (PyStr_Check(inargs)) { /* Input argument is just a string */
227227
fetch_devs_len = 1;
228228
fetch_devs = calloc(1, sizeof(char *));
229229
fetch_devs[0] = PyStr_AsString(inargs);
230230

231-
} else if (PyTuple_Check(inargs)) { /* Input argument is a tuple list with devices */
231+
} else if (PyTuple_Check(inargs)) { /* Input argument is a tuple list with devices */
232232
int j = 0;
233233

234234
fetch_devs_len = PyTuple_Size(inargs);
@@ -240,7 +240,7 @@ static PyObject *get_interfaces_info(PyObject *self __unused, PyObject *args) {
240240
}
241241
}
242242
fetch_devs_len = j;
243-
} else if (PyList_Check(inargs)) { /* Input argument is a list with devices */
243+
} else if (PyList_Check(inargs)) { /* Input argument is a list with devices */
244244
int j = 0;
245245

246246
fetch_devs_len = PyList_Size(inargs);

0 commit comments

Comments
 (0)