Skip to content

Commit e1d3b7d

Browse files
skirpichevvstinner
andauthored
Update Modules/_struct.c
Co-authored-by: Victor Stinner <vstinner@python.org>
1 parent d90dfc2 commit e1d3b7d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Modules/_struct.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1831,7 +1831,8 @@ s_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
18311831
}
18321832
}
18331833
else {
1834-
if (s_create(self, PyTuple_GET_ITEM(args, 0))) {
1834+
PyObject *format = PyTuple_GET_ITEM(args, 0);
1835+
if (s_create(self, format)) {
18351836
goto err;
18361837
}
18371838
}

0 commit comments

Comments
 (0)