lib:printer_driver: Handle PrintProcessor string
authorJustin Stephenson <jstephen@redhat.com>
Fri, 16 Nov 2018 21:03:00 +0000 (16:03 -0500)
committerBjoern Jacke <bjacke@samba.org>
Mon, 28 Jan 2019 14:44:18 +0000 (15:44 +0100)
This fixes an issue parsing the section of a certain HP
driver inf file:

PrintProcessor=%PRINT_PROCESSOR%

where %PRINT_PROCESSOR% is a [Strings] substituted value,
gp_inifile_getstring_ext() performs the substitution correctly.

Signed-off-by: Justin Stephenson <jstephen@redhat.com>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Bjoern Jacke <bjacke@samba.org>
lib/printer_driver/printer_driver.c

index ea5d9efdbe8daf8d9a154ef8732568f0f57a7ad5..50616a869f353f25b3e66b593591b01174769a28 100644 (file)
@@ -589,7 +589,7 @@ static NTSTATUS process_driver_section_printprocessor(struct gp_inifile_context
                return NT_STATUS_NO_MEMORY;
        }
 
-       status = gp_inifile_getstring(ctx, key, &s);
+       status = gp_inifile_getstring_ext(ctx, key, &s);
        if (NT_STATUS_IS_OK(status)) {
                s = get_string_unquote(s);