Skip to content

Commit 7484e48

Browse files
committed
Add missing value tag test to cupsCheckDestSupported.
1 parent c869107 commit 7484e48

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

CHANGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,7 @@ v2.5b1 - YYYY-MM-DD
172172
- Fixed A4 support in the `ippevepcl` program (Issue #1544)
173173
- Fixed issues with the environment variable support of CGI programs
174174
(Issue #1547)
175+
- Fixed potential crash bug in `cupsCheckDestSupported` function.
175176
- Removed hash support for SHA2-512-224 and SHA2-512-256.
176177
- Removed `mantohtml` script for generating html pages (use
177178
`https://www.msweet.org/mantohtml/`)

cups/dest-options.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ cupsCheckDestSupported(
304304
* Compare values...
305305
*/
306306

307-
if (!strcmp(option, "media") && !strncmp(value, "custom_", 7))
307+
if (!strcmp(option, "media") && (ippGetValueTag(attr) == IPP_TAG_KEYWORD || ippGetValueTag(attr) == IPP_TAG_NAME || ippGetValueTag(attr) == IPP_TAG_NAMELANG) && !strncmp(value, "custom_", 7))
308308
{
309309
/*
310310
* Check range of custom media sizes...

0 commit comments

Comments
 (0)