From: Michael R Sweet Date: Tue, 1 Apr 2025 18:53:22 +0000 (-0400) Subject: Avoid double make strings (Make Make Model) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=22f8fba7823b04d42ec1c8fc3ee9898abd01ea35;p=thirdparty%2Fcups.git Avoid double make strings (Make Make Model) --- diff --git a/backend/dnssd.c b/backend/dnssd.c index 006becbdbe..2db9fe642a 100644 --- a/backend/dnssd.c +++ b/backend/dnssd.c @@ -1,7 +1,7 @@ // // DNS-SD discovery backend for CUPS. // -// Copyright © 2020-2024 by OpenPrinting. +// Copyright © 2020-2025 by OpenPrinting. // Copyright © 2008-2018 by Apple Inc. // // Licensed under Apache License v2.0. See the file "LICENSE" for more @@ -666,7 +666,7 @@ query_callback( if (device->make_and_model) free(device->make_and_model); - if (make_and_model[0]) + if (make_and_model[0] && strncmp(make_and_model, model, strlen(make_and_model))) { cupsConcatString(make_and_model, " ", sizeof(make_and_model)); cupsConcatString(make_and_model, model, sizeof(make_and_model));