Skip to content

Commit

Permalink
cups: fix NixOS#195090
Browse files Browse the repository at this point in the history
Patch message is in that file; also submitted upstream but that will
probably take a while, so this is a stopgap until then.
  • Loading branch information
ckiee committed Jan 2, 2023
1 parent 051d49b commit 2d71382
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 29 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
From 7225df2a2a52309dcb11922d718f79329cbdaefb Mon Sep 17 00:00:00 2001
From: ckie <git-525ff67@ckie.dev>
Date: Mon, 2 Jan 2023 00:20:51 +0200
Subject: [PATCH] Increase log level for "Expiring subscriptions..."

Fixes https://github.com/NixOS/nixpkgs/issues/195090.

NixOS systems with Avahi enabled would previously spam the journal with
this log message once a second: this hides that spam behind the log level.
---
scheduler/subscriptions.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scheduler/subscriptions.c b/scheduler/subscriptions.c
index 2dbb28f85..9b31ec250 100644
--- a/scheduler/subscriptions.c
+++ b/scheduler/subscriptions.c
@@ -621,7 +621,7 @@ cupsdExpireSubscriptions(
curtime = time(NULL);
update = 0;

- cupsdLogMessage(CUPSD_LOG_INFO, "Expiring subscriptions...");
+ cupsdLogMessage(CUPSD_LOG_DEBUG, "Expiring subscriptions...");

for (sub = (cupsd_subscription_t *)cupsArrayFirst(Subscriptions);
sub;
--
2.38.1

29 changes: 0 additions & 29 deletions pkgs/misc/cups/0001-TargetConditionals.patch

This file was deleted.

4 changes: 4 additions & 0 deletions pkgs/misc/cups/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ stdenv.mkDerivation rec {

outputs = [ "out" "lib" "dev" "man" ];

patches = [
./0001-Increase-log-level-for-Expiring-subscriptions.patch
];

postPatch = ''
substituteInPlace cups/testfile.c \
--replace 'cupsFileFind("cat", "/bin' 'cupsFileFind("cat", "${coreutils}/bin'
Expand Down

0 comments on commit 2d71382

Please sign in to comment.