[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 2/2] Replace UTF8_STRING with OEM_STRING


  • To: win-pv-devel@xxxxxxxxxxxxxxxxxxxx
  • From: "Durrant, Paul" <xadimgnik@xxxxxxxxx>
  • Date: Wed, 22 Sep 2021 10:55:45 +0100
  • Delivery-date: Wed, 22 Sep 2021 09:55:50 +0000
  • List-id: Developer list for the Windows PV Drivers subproject <win-pv-devel.lists.xenproject.org>

On 21/09/2021 11:45, Owen Smith wrote:
The UTF8 conversion functions treat UTF8_STRING as:
   struct {
       USHORT  Length;
       CHAR    Buffer[ANYSIZE_ARRAY];
   } UTF8_STRING;

But UTF8_STRING is defined by later WDKs as:
   struct {
       USHORT  Length;
       USHORT  MaximumLength;
       PCHAR   Buffer;
   } UTF8_STRING;

This difference leads to an 0x3B BSOD when anything attempts to use any WMI
method that deals with strings.

Replace UTF8_STRING with OEM_STRING which is available in all WDKs, and has
the same definition as UTF8_STRING from later WDKs, simplifying the usage
of retrieving strings from, or putting strings into, WMI buffers.

Signed-off-by: Owen Smith <owen.smith@xxxxxxxxxx>

Acked-by: Paul Durrant <paul@xxxxxxx>



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.