From 94f925c815586221da10dcc5fcbadf9fb04a98f4 Mon Sep 17 00:00:00 2001 From: David Disseldorp Date: Wed, 23 Nov 2011 02:03:48 +0100 Subject: [PATCH] idl: add to_null attribute to the spoolss devicename array OpenPrinterEx requests have also been observed in the wild carrying non-utf16 garbage after the device mode devicename field null terminator. Signed-off-by: Jeremy Allison --- librpc/idl/spoolss.idl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/librpc/idl/spoolss.idl b/librpc/idl/spoolss.idl index 4b1f94f4a353..d888a79ecba9 100644 --- a/librpc/idl/spoolss.idl +++ b/librpc/idl/spoolss.idl @@ -678,7 +678,7 @@ cpp_quote("#define spoolss_security_descriptor security_descriptor") const int MAXDEVICENAME = 32; typedef [public,gensize] struct { - [charset(UTF16)] uint16 devicename[MAXDEVICENAME]; + [charset(UTF16),to_null] uint16 devicename[MAXDEVICENAME]; spoolss_DeviceModeSpecVersion specversion; uint16 driverversion; uint16 size; -- 2.34.1