Skip to content

Commit

Permalink
Apply style suggestions.
Browse files Browse the repository at this point in the history
  • Loading branch information
serhiy-storchaka committed Oct 17, 2024
1 parent ca215dd commit d4fcbf3
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions Modules/timemodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -776,9 +776,9 @@ the C library strftime function.\n"
#endif

static PyObject *
strftime1(time_char **outbuf, size_t *bufsize,
time_char *format, size_t fmtlen,
struct tm *tm)
time_strftime1(time_char **outbuf, size_t *bufsize,
time_char *format, size_t fmtlen,
struct tm *tm)
{
size_t buflen;
#if defined(MS_WINDOWS) && !defined(HAVE_WCSFTIME)
Expand Down Expand Up @@ -823,7 +823,7 @@ strftime1(time_char **outbuf, size_t *bufsize,
return NULL;
}
*outbuf = (time_char *)PyMem_Realloc(*outbuf,
*bufsize*sizeof(time_char));
*bufsize*sizeof(time_char));
if (*outbuf == NULL) {
PyErr_NoMemory();
return NULL;
Expand Down Expand Up @@ -932,7 +932,8 @@ time_strftime(PyObject *module, PyObject *args)
}
if (fmtlen) {
format[fmtlen] = 0;
PyObject *unicode = strftime1(&outbuf, &bufsize, format, fmtlen, &buf);
PyObject *unicode = time_strftime1(&outbuf, &bufsize,
format, fmtlen, &buf);
if (unicode == NULL) {
goto error;
}
Expand Down

0 comments on commit d4fcbf3

Please sign in to comment.