From: ValdikSS Date: Sun, 11 Feb 2024 00:55:37 +0300 Subject: Use XML Make or Model for 1284DeviceID line if other info is missing (#11) Windows 10 and 11 require 1284DeviceID to contain MFG and MDL elements, otherwise the shared printer would silently fail upon adding (or install endlessly, without any error). If the XML file does not have section, use general and data to construct 1284DeviceID. (cherry picked from commit fa91bdfd87da9005591ac2ef2c9c7b8ecdd19511) --- lib/Foomatic/DB.pm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/Foomatic/DB.pm b/lib/Foomatic/DB.pm index e893c0f..0669b5b 100644 --- a/lib/Foomatic/DB.pm +++ b/lib/Foomatic/DB.pm @@ -3272,11 +3272,13 @@ sub deviceIDfromDBEntry { my $pnpmake; $pnpmake = $ieeemake or $pnpmake = $dat->{'general_mfg'} or $pnpmake = $dat->{'pnp_mfg'} or $pnpmake = $dat->{'par_mfg'} or - $pnpmake = $dat->{'usb_mfg'} or $pnpmake = ""; + $pnpmake = $dat->{'usb_mfg'} or $pnpmake = $dat->{'make'} or + $pnpmake = ""; my $pnpmodel; $pnpmodel = $ieeemodel or $pnpmodel = $dat->{'general_mdl'} or $pnpmodel = $dat->{'pnp_mdl'} or $pnpmodel = $dat->{'par_mdl'} or - $pnpmodel = $dat->{'usb_mdl'} or $pnpmodel = ""; + $pnpmodel = $dat->{'usb_mdl'} or $pnpmodel = $dat->{'model'} or + $pnpmodel = ""; my $pnpcmd; $pnpcmd = $ieeecmd or $pnpcmd = $dat->{'general_cmd'} or $pnpcmd = $dat->{'pnp_cmd'} or $pnpcmd = $dat->{'par_cmd'} or