Re: A couple of questions regarding IPP specs
Michael Sweet <[email protected]> Thu, 21 Mar 2024 14:41:50 -0400
| Newsgroups | dev.linux.lists.printing-architecture |
|---|---|
| Message-ID | <[email protected]> |
Alexander, > On Mar 21, 2024, at 1:25 PM, Alexander Pevzner <[email protected]> wrote: > > Hi Everybody, > > I have a couple of questions regarding IPP specs. > > 1) Are attribute names case-sensitive or not? Is the answer the same for top-level attributes and for member attributes within a collection? Yes, and yes. Technically attribute names are keywords which are supposed to be lowercase only, but the IPP workgroup relaxed that requirement around the time we published RFCs 8010 and 8011 (what is collectively known as STD 92). > In the CUPS sources, in the ippFindNextAttribute(), I see name is used twice for comparison, with strcmp() in one place and with _cups_strcasecmp() in another place... That would be a bug, they should both be using strcmp. It dates from before 2011 so I'll have to do some serious digging into the old Subversion repository to get that history... > 2) If two or more attributes in the same scope have the same name, how the conforming implementation SHOULD behave: ignore the second occurrence (seems, CUPS does this way), reject such a message with an error or merge values? The encoding doesn't explicitly prevent it but the semantics *do*. Except for ipptool, CUPS ignores subsequent occurrences for performance reasons. ________________________ Michael Sweet