Skip to content

Commit 187dd1e

Browse files
committed
Add "WITH-VALUE !number" comparison for ipptool.
Clean up man pages.
1 parent 91ee19d commit 187dd1e

5 files changed

Lines changed: 31 additions & 21 deletions

File tree

doc/help/man-cups-x509.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<body>
88
<h1 id="cups-x509-1">cups-x509(1)</h1>
99
<h2 id="cups-x509-1.name">Name</h2>
10-
<p>cups-x509 - description
10+
<p>cups-x509 - manage x.509 certificates and certificate requests
1111
</p>
1212
<h2 id="cups-x509-1.synopsis">Synopsis</h2>
1313
<p><strong>cups-x509</strong>

doc/help/man-ipptoolfile.html

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -402,15 +402,17 @@ <h3 id="ipptoolfile-5.description.expect-predicates">Expect Predicates</h3>
402402
</p>
403403
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES &quot;</strong><em>literal string</em><strong>&quot;</strong><br>
404404
Requires that all values of the <strong>EXPECT</strong> attribute match the literal string. Comparisons are case-sensitive.
405-
</p>
406-
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES &lt;</strong><em>number</em><br>
407405
</p>
408406
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES =</strong><em>number</em><br>
407+
</p>
408+
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES !</strong><em>number</em><br>
409+
</p>
410+
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES &lt;</strong><em>number</em><br>
409411
</p>
410412
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES ></strong><em>number</em><br>
411413
</p>
412414
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES </strong><em>number</em>[<em>,...,number</em>]<br>
413-
Requires that all values of the <strong>EXPECT</strong> attribute match the number(s) or numeric comparison. When comparing rangeOfInteger values, the &quot;&lt;&quot; and &quot;>&quot; operators only check the upper bound of the range.
415+
Requires that all values of the <strong>EXPECT</strong> attribute match (&quot;=&quot;), do not match (&quot;!&quot;), are less than (&quot;&lt;&quot;), or are greater than (&quot;>&quot;) the number(s). When comparing rangeOfInteger values, the &quot;&lt;&quot; and &quot;>&quot; operators only check the upper bound of the range, &quot;=&quot; checks for inclusion in a range, and &quot;!&quot; checks for exclusion of a range.
414416
</p>
415417
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-ALL-VALUES &quot;false&quot;</strong><br>
416418
</p>
@@ -447,15 +449,17 @@ <h3 id="ipptoolfile-5.description.expect-predicates">Expect Predicates</h3>
447449
</p>
448450
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE &quot;</strong><em>literal string</em><strong>&quot;</strong><br>
449451
Requires that at least one value of the <strong>EXPECT</strong> attribute matches the literal string. Comparisons are case-sensitive.
450-
</p>
451-
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE &lt;</strong><em>number</em><br>
452452
</p>
453453
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE =</strong><em>number</em><br>
454+
</p>
455+
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE !</strong><em>number</em><br>
456+
</p>
457+
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE &lt;</strong><em>number</em><br>
454458
</p>
455459
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE ></strong><em>number</em><br>
456460
</p>
457461
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE </strong><em>number</em>[<em>,...,number</em>]<br>
458-
Requires that at least one value of the <strong>EXPECT</strong> attribute matches the number(s) or numeric comparison. When comparing rangeOfInteger values, the &quot;&lt;&quot; and &quot;>&quot; operators only check the upper bound of the range.
462+
Requires that at least one value of the <strong>EXPECT</strong> attribute matches (&quot;=&quot;), does not match (&quot;!&quot;), is less than (&quot;&lt;&quot;), or is greater than (&quot;>&quot;) the number(s). When comparing rangeOfInteger values, the &quot;&lt;&quot; and &quot;>&quot; operators only check the upper bound of the range, &quot;=&quot; checks for inclusion in a range, and &quot;!&quot; checks for exclusion of a range.
459463
</p>
460464
<p style="margin-left: 2.5em; text-indent: -2.5em;"><strong>WITH-VALUE &quot;false&quot;</strong><br>
461465
</p>

man/cups-x509.1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
.\" Licensed under Apache License v2.0. See the file "LICENSE" for more
77
.\" information.
88
.\"
9-
.TH cups-x509 1 "CUPS" "2025-10-21" "OpenPrinting"
9+
.TH cups-x509 1 "CUPS" "2025-10-23" "OpenPrinting"
1010
.SH NAME
11-
cups-x509 \- description
11+
cups-x509 \- manage x.509 certificates and certificate requests
1212
.SH SYNOPSIS
1313
.B cups-x509
1414
.B \-\-help

man/ipptoolfile.5

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
.\" Licensed under Apache License v2.0. See the file "LICENSE" for more
88
.\" information.
99
.\"
10-
.TH ipptoolfile 5 "CUPS" "2024-09-12" "OpenPrinting"
10+
.TH ipptoolfile 5 "CUPS" "2024-10-23" "OpenPrinting"
1111
.SH NAME
1212
ipptoolfile \- ipptool file format
1313
.SH DESCRIPTION
@@ -391,14 +391,16 @@ Requires that all URI values contain a matching scheme.
391391
\fBWITH\-ALL\-VALUES "\fIliteral string\fB"\fR
392392
Requires that all values of the \fBEXPECT\fR attribute match the literal string. Comparisons are case-sensitive.
393393
.TP 5
394-
\fBWITH\-ALL\-VALUES <\fInumber\fR
395-
.TP 5
396394
\fBWITH\-ALL\-VALUES =\fInumber\fR
397395
.TP 5
396+
\fBWITH\-ALL\-VALUES !\fInumber\fR
397+
.TP 5
398+
\fBWITH\-ALL\-VALUES <\fInumber\fR
399+
.TP 5
398400
\fBWITH\-ALL\-VALUES >\fInumber\fR
399401
.TP 5
400402
\fBWITH\-ALL\-VALUES \fInumber\fR[\fI,...,number\fR]
401-
Requires that all values of the \fBEXPECT\fR attribute match the number(s) or numeric comparison. When comparing rangeOfInteger values, the "<" and ">" operators only check the upper bound of the range.
403+
Requires that all values of the \fBEXPECT\fR attribute match ("="), do not match ("!"), are less than ("<"), or are greater than (">") the number(s). When comparing rangeOfInteger values, the "<" and ">" operators only check the upper bound of the range, "=" checks for inclusion in a range, and "!" checks for exclusion of a range.
402404
.TP 5
403405
\fBWITH\-ALL\-VALUES "false"\fR
404406
.TP 5
@@ -436,14 +438,16 @@ Requires that at least one URI value contains a matching scheme.
436438
\fBWITH\-VALUE "\fIliteral string\fB"\fR
437439
Requires that at least one value of the \fBEXPECT\fR attribute matches the literal string. Comparisons are case-sensitive.
438440
.TP 5
439-
\fBWITH\-VALUE <\fInumber\fR
440-
.TP 5
441441
\fBWITH\-VALUE =\fInumber\fR
442442
.TP 5
443+
\fBWITH\-VALUE !\fInumber\fR
444+
.TP 5
445+
\fBWITH\-VALUE <\fInumber\fR
446+
.TP 5
443447
\fBWITH\-VALUE >\fInumber\fR
444448
.TP 5
445449
\fBWITH\-VALUE \fInumber\fR[\fI,...,number\fR]
446-
Requires that at least one value of the \fBEXPECT\fR attribute matches the number(s) or numeric comparison. When comparing rangeOfInteger values, the "<" and ">" operators only check the upper bound of the range.
450+
Requires that at least one value of the \fBEXPECT\fR attribute matches ("="), does not match ("!"), is less than ("<"), or is greater than (">") the number(s). When comparing rangeOfInteger values, the "<" and ">" operators only check the upper bound of the range, "=" checks for inclusion in a range, and "!" checks for exclusion of a range.
447451
.TP 5
448452
\fBWITH\-VALUE "false"\fR
449453
.TP 5

tools/ipptool.c

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7205,12 +7205,12 @@ with_value(ipptool_test_t *data, // I - Test data
72057205

72067206
while (isspace(*valptr & 255) || isdigit(*valptr & 255) ||
72077207
*valptr == '-' || *valptr == ',' || *valptr == '<' ||
7208-
*valptr == '=' || *valptr == '>')
7208+
*valptr == '=' || *valptr == '>' || *valptr == '!')
72097209
{
72107210
op = '=';
72117211
while (*valptr && !isdigit(*valptr & 255) && *valptr != '-')
72127212
{
7213-
if (*valptr == '<' || *valptr == '>' || *valptr == '=')
7213+
if (*valptr == '<' || *valptr == '>' || *valptr == '=' || *valptr == '!')
72147214
op = *valptr;
72157215
valptr ++;
72167216
}
@@ -7224,6 +7224,7 @@ with_value(ipptool_test_t *data, // I - Test data
72247224
valptr = nextptr;
72257225

72267226
if ((op == '=' && attrvalue == intvalue) ||
7227+
(op == '!' && attrvalue != intvalue) ||
72277228
(op == '<' && attrvalue < intvalue) ||
72287229
(op == '>' && attrvalue > intvalue))
72297230
{
@@ -7271,13 +7272,13 @@ with_value(ipptool_test_t *data, // I - Test data
72717272
valptr = value;
72727273

72737274
while (isspace(*valptr & 255) || isdigit(*valptr & 255) ||
7274-
*valptr == '-' || *valptr == ',' || *valptr == '<' ||
7275+
*valptr == '-' || *valptr == ',' || *valptr == '!' || *valptr == '<' ||
72757276
*valptr == '=' || *valptr == '>')
72767277
{
72777278
op = '=';
72787279
while (*valptr && !isdigit(*valptr & 255) && *valptr != '-')
72797280
{
7280-
if (*valptr == '<' || *valptr == '>' || *valptr == '=')
7281+
if (*valptr == '<' || *valptr == '>' || *valptr == '=' || *valptr == '!')
72817282
op = *valptr;
72827283
valptr ++;
72837284
}
@@ -7290,7 +7291,8 @@ with_value(ipptool_test_t *data, // I - Test data
72907291
break;
72917292
valptr = nextptr;
72927293

7293-
if ((op == '=' && (lower == intvalue || upper == intvalue)) ||
7294+
if ((op == '=' && lower <= intvalue && upper >= intvalue) ||
7295+
(op == '!' && (lower > intvalue || upper < intvalue)) ||
72947296
(op == '<' && upper < intvalue) ||
72957297
(op == '>' && upper > intvalue))
72967298
{

0 commit comments

Comments
 (0)