Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit fe28fa0

Browse files
committed
Remove the last three uses of PyArg_GetInt() from the source.
1 parent 4c4d5ce commit fe28fa0

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Modules/socketmodule.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -522,7 +522,7 @@ BUILD_FUNC_DEF_2(PySocketSock_setblocking,PySocketSockObject*,s,PyObject*,args)
522522
#ifndef MS_WINDOWS
523523
int delay_flag;
524524
#endif
525-
if (!PyArg_GetInt(args, &block))
525+
if (!PyArg_Parse(args, "i", &block))
526526
return NULL;
527527
Py_BEGIN_ALLOW_THREADS
528528
#ifndef MS_WINDOWS
@@ -766,7 +766,7 @@ BUILD_FUNC_DEF_2(PySocketSock_listen,PySocketSockObject *,s, PyObject *,args)
766766
{
767767
int backlog;
768768
int res;
769-
if (!PyArg_GetInt(args, &backlog))
769+
if (!PyArg_Parse(args, "i", &backlog))
770770
return NULL;
771771
Py_BEGIN_ALLOW_THREADS
772772
if (backlog < 1)
@@ -938,7 +938,7 @@ BUILD_FUNC_DEF_2(PySocketSock_shutdown,PySocketSockObject *,s, PyObject *,args)
938938
{
939939
int how;
940940
int res;
941-
if (!PyArg_GetInt(args, &how))
941+
if (!PyArg_Parse(args, "i", &how))
942942
return NULL;
943943
Py_BEGIN_ALLOW_THREADS
944944
res = shutdown(s->sock_fd, how);

0 commit comments

Comments
 (0)