]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
printers.c: Set .strings file path if PPD cache is valid (fixes #710) 711/head
authorZdenek Dohnal <zdohnal@redhat.com>
Thu, 1 Jun 2023 13:57:36 +0000 (15:57 +0200)
committerZdenek Dohnal <zdohnal@redhat.com>
Thu, 1 Jun 2023 13:57:36 +0000 (15:57 +0200)
CHANGES.md
scheduler/printers.c

index e926cf797c8183794389bd8bcb1a5516708903a6..94171d1d758061d4b0b64a4feeca155ecefca09f 100644 (file)
@@ -15,6 +15,9 @@ Changes in CUPS v2.4.3 (TBA)
 - Fixed a potential SNMP OID value overflow issue (Issue #431)
 - Fixed an OpenSSL certificate loading issue (Issue #465)
 - Fixed Brazilian Portuguese translations (Issue #288)
+- Fixed `cupsd` default keychain location when building with OpenSSL
+  (Issue #529)
+- Fixed default color settings for CMYK printers as well (Issue #500)
 - Fixed duplicate PPD2IPP media-type names (Issue #688)
 - Fixed possible heap buffer overflow in `_cups_strlcpy()` (fixes CVE-2023-32324)
 - Fixed InputSlot heuristic for photo sizes smaller than 5x7" if there is no
@@ -25,9 +28,7 @@ Changes in CUPS v2.4.3 (TBA)
 - Fixed memory leaks in `create_local_bg_thread()` (Issue #466)
 - Fixed media size tolerance in `ippeveprinter` (Issue #487)
 - Fixed passing command name without path into `ippeveprinter` (Issue #629)
-- Fixed `cupsd` default keychain location when building with OpenSSL
-  (Issue #529)
-- Fixed default color settings for CMYK printers as well (Issue #500)
+- Fixed saving strings file path in `printers.conf` (Issue #710)
 - Fixed TLS certificate generation bugs (Issue #652)
 - `ippDeleteValues` would not delete the last value (Issue #556)
 - Ignore some of IPP defaults if the application sends its PPD alternative
index ea554c0e2bfd7c6275876176b26484d8de67fe3f..5f9852e64f661e3242ea7f30a1ba84bc4261cc3f 100644 (file)
@@ -3935,6 +3935,16 @@ load_ppd(cupsd_printer_t *p)             /* I - Printer */
       * Loaded successfully!
       */
 
+     /*
+      * Set `strings` (source for printer-strings-uri IPP attribute)
+      * if printer's .strings file with localization exists.
+      */
+
+      if (!access(strings_name, R_OK))
+       cupsdSetString(&p->strings, strings_name);
+      else
+       cupsdClearString(&p->strings);
+
       return;
     }
   }