Skip to content

cups-browsed: don't use name@host for IPP printers with DNS-SD naming - #78

Merged
tillkamppeter merged 1 commit into
OpenPrinting:masterfrom
Ar-maan05:dnssd-name-fallback
Nov 2, 2026
Merged

tillkamppeter merged 1 commit into
OpenPrinting:masterfrom
Ar-maan05:dnssd-name-fallback

Conversation

@Ar-maan05

Copy link
Copy Markdown
Contributor

get_local_queue_name() tests the is_cups_queue pointer in one place instead of what it points to, so the check for IPP printers is always true.

with default settings, a discovered IPP printer "Office Printer" and a manual queue already called Office_Printer:

before: Office_Printer@printer.local
after:  (ignored, "No suitable local queue name found")

the comment right above says name@host is only for when DNS-SD naming isn't used, and the line above it already does *is_cups_queue for the remote CUPS case. a printer whose name is free still gets Free_One as before, and other naming modes aren't affected.

this does change behavior, since those printers stop getting a name@host queue. that's what the comment describes, but tell me if people have come to rely on it.

tested with a small harness calling the function directly, before and after, without a live cupsd or avahi.

get_local_queue_name() only wants to fall back to name@host when DNS-SD service name based naming isn't used. the check for IPP printers tested the is_cups_queue pointer instead of its value, wich is always true, so the fallback was used for them anyway. with the default settings, a printer whose name is taken by a manual queue got a name@host queue instead of being ignored.
@tillkamppeter
tillkamppeter merged commit 65d4732 into OpenPrinting:master Nov 2, 2026
11 checks passed
@Ar-maan05
Ar-maan05 deleted the dnssd-name-fallback branch November 2, 2026 23:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants