diff options
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/_ctypes/_ctypes.c | 6 | ||||
-rw-r--r-- | Modules/_localemodule.c | 3 | ||||
-rw-r--r-- | Modules/fcntlmodule.c | 2 | ||||
-rw-r--r-- | Modules/signalmodule.c | 14 | ||||
-rw-r--r-- | Modules/socketmodule.c | 11 |
5 files changed, 19 insertions, 17 deletions
diff --git a/Modules/_ctypes/_ctypes.c b/Modules/_ctypes/_ctypes.c index 7de9cee..2935292 100644 --- a/Modules/_ctypes/_ctypes.c +++ b/Modules/_ctypes/_ctypes.c @@ -5138,18 +5138,18 @@ comerror_init(PyObject *self, PyObject *args, PyObject *kwds) int status; if (!_PyArg_NoKeywords(Py_TYPE(self)->tp_name, kwds)) - return -1; + return -1; if (!PyArg_ParseTuple(args, "OOO:COMError", &hresult, &text, &details)) return -1; a = PySequence_GetSlice(args, 1, PySequence_Size(args)); if (!a) - return -1; + return -1; status = PyObject_SetAttrString(self, "args", a); Py_DECREF(a); if (status < 0) - return -1; + return -1; if (PyObject_SetAttrString(self, "hresult", hresult) < 0) return -1; diff --git a/Modules/_localemodule.c b/Modules/_localemodule.c index b1d6add..b1307ef 100644 --- a/Modules/_localemodule.c +++ b/Modules/_localemodule.c @@ -54,9 +54,10 @@ copy_grouping(char* s) int i; PyObject *result, *val = NULL; - if (s[0] == '\0') + if (s[0] == '\0') { /* empty string: no grouping at all */ return PyList_New(0); + } for (i = 0; s[i] != '\0' && s[i] != CHAR_MAX; i++) ; /* nothing */ diff --git a/Modules/fcntlmodule.c b/Modules/fcntlmodule.c index 7bd18ac..8875b26 100644 --- a/Modules/fcntlmodule.c +++ b/Modules/fcntlmodule.c @@ -26,7 +26,7 @@ conv_descriptor(PyObject *object, int *target) int fd = PyObject_AsFileDescriptor(object); if (fd < 0) - return 0; + return 0; *target = fd; return 1; } diff --git a/Modules/signalmodule.c b/Modules/signalmodule.c index a1a18b0..753d987 100644 --- a/Modules/signalmodule.c +++ b/Modules/signalmodule.c @@ -154,18 +154,18 @@ itimer_retval(struct itimerval *iv) r = PyTuple_New(2); if (r == NULL) - return NULL; + return NULL; if(!(v = PyFloat_FromDouble(double_from_timeval(&iv->it_value)))) { - Py_DECREF(r); - return NULL; + Py_DECREF(r); + return NULL; } PyTuple_SET_ITEM(r, 0, v); if(!(v = PyFloat_FromDouble(double_from_timeval(&iv->it_interval)))) { - Py_DECREF(r); - return NULL; + Py_DECREF(r); + return NULL; } PyTuple_SET_ITEM(r, 1, v); @@ -1479,9 +1479,9 @@ PyInit__signal(void) #if defined (HAVE_SETITIMER) || defined (HAVE_GETITIMER) ItimerError = PyErr_NewException("signal.ItimerError", - PyExc_IOError, NULL); + PyExc_IOError, NULL); if (ItimerError != NULL) - PyDict_SetItemString(d, "ItimerError", ItimerError); + PyDict_SetItemString(d, "ItimerError", ItimerError); #endif #ifdef CTRL_C_EVENT diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c index d059617..3e1a460 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -1967,12 +1967,13 @@ getsockaddrlen(PySocketSockObject *s, socklen_t *len_ret) return 1; } #endif /* AF_UNIX */ + #if defined(AF_NETLINK) - case AF_NETLINK: - { - *len_ret = sizeof (struct sockaddr_nl); - return 1; - } + case AF_NETLINK: + { + *len_ret = sizeof (struct sockaddr_nl); + return 1; + } #endif #ifdef AF_RDS |