Skip to content

Commit a0e331a

Browse files
committed
Fix raw_data signature
1 parent 0e9953e commit a0e331a

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

Modules/_winapi.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3048,7 +3048,7 @@ _winapi.ReportEvent
30483048
The event identifier.
30493049
strings: object(subclass_of='&PyList_Type')
30503050
A list of strings to be inserted into the event message.
3051-
raw_data: Py_buffer = None
3051+
raw_data: Py_buffer(accept={str, buffer, NoneType}) = None
30523052
The raw data for the event.
30533053
30543054
Writes an entry at the end of the specified event log.
@@ -3059,7 +3059,7 @@ _winapi_ReportEvent_impl(PyObject *module, HANDLE handle,
30593059
unsigned short type, unsigned short category,
30603060
unsigned int event_id, PyObject *strings,
30613061
Py_buffer *raw_data)
3062-
/*[clinic end generated code: output=fc3bbbde78cffd6c input=d4159129e760b095]*/
3062+
/*[clinic end generated code: output=fc3bbbde78cffd6c input=abcc01d4fc284975]*/
30633063
{
30643064
BOOL success;
30653065
LPCWSTR *string_array = NULL;
@@ -3080,7 +3080,7 @@ _winapi_ReportEvent_impl(PyObject *module, HANDLE handle,
30803080
PyErr_SetString(PyExc_ValueError, "raw_data is too large");
30813081
return NULL;
30823082
}
3083-
if (raw_data->buf != NULL) {
3083+
if (raw_data->obj != NULL) {
30843084
data = raw_data->buf;
30853085
data_size = (DWORD)raw_data->len;
30863086
}

Modules/clinic/_winapi.c.h

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)