Change def of OBJECT_ATTRIBUTES struct to handle remotectypes (#51)

This commit is contained in:
hakril
2024-05-18 23:11:35 +02:00
committed by GitHub
parent d8b2770046
commit f92204a16f
3 changed files with 6 additions and 4 deletions
@@ -13,4 +13,5 @@ class _OBJECT_ATTRIBUTES(_OBJECT_ATTRIBUTES):
def __repr__(self):
if not self.ObjectName:
return super(_OBJECT_ATTRIBUTES, self).__repr__()
return """<{0} ObjectName="{1}">""".format(type(self).__name__, self.ObjectName[0].str)
# .contents allow compatibility with remotectypes
return """<{0} ObjectName="{1}">""".format(type(self).__name__, self.ObjectName.contents.str)
+2 -2
View File
@@ -21374,9 +21374,9 @@ _OVERLAPPED
:class:`ULONG_PTR`
.. attribute:: Pointer
.. attribute:: _ANON_OVERLAPPED_DUMMYUNIONNAME
:class:`PVOID`
:class:`_ANON__OVERLAPPED_SUB_UNION_1`
.. attribute:: hEvent
+2 -1
View File
@@ -5947,7 +5947,8 @@ class _OBJECT_ATTRIBUTES(_OBJECT_ATTRIBUTES):
def __repr__(self):
if not self.ObjectName:
return super(_OBJECT_ATTRIBUTES, self).__repr__()
return """<{0} ObjectName="{1}">""".format(type(self).__name__, self.ObjectName[0].str)
# .contents allow compatibility with remotectypes
return """<{0} ObjectName="{1}">""".format(type(self).__name__, self.ObjectName.contents.str)
POBJECT_ATTRIBUTES = POINTER(_OBJECT_ATTRIBUTES)
OBJECT_ATTRIBUTES = _OBJECT_ATTRIBUTES
class _TMP_UNION_IO_STATUS_BLOCK(Union):