Avoid criticals on headless systems
Resolve: RHEL-40884
This commit is contained in:
parent
07aecb24a7
commit
4b51d83f89
30
0001-Avoid-criticals-on-headless-systems.patch
Normal file
30
0001-Avoid-criticals-on-headless-systems.patch
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
From f22e5b0b23fcd59fc965c827b4036b212a603536 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Matthias Clasen <mclasen@redhat.com>
|
||||||
|
Date: Thu, 22 Aug 2024 11:20:17 -0400
|
||||||
|
Subject: [PATCH] Avoid criticals on headless systems
|
||||||
|
|
||||||
|
If we don't have a monitor, don't try to use it.
|
||||||
|
This avoids pointless critical warnings on headless systems.
|
||||||
|
---
|
||||||
|
gtk/gtkwidget.c | 5 ++++-
|
||||||
|
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
|
||||||
|
index b6e00115bb..23401a44e8 100644
|
||||||
|
--- a/gtk/gtkwidget.c
|
||||||
|
+++ b/gtk/gtkwidget.c
|
||||||
|
@@ -10984,7 +10984,10 @@ gtk_widget_get_scale_factor (GtkWidget *widget)
|
||||||
|
display = gtk_widget_get_display (widget);
|
||||||
|
monitor = gdk_display_get_monitor (display, 0);
|
||||||
|
|
||||||
|
- return gdk_monitor_get_scale_factor (monitor);
|
||||||
|
+ if (monitor)
|
||||||
|
+ return gdk_monitor_get_scale_factor (monitor);
|
||||||
|
+
|
||||||
|
+ return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
--
|
||||||
|
2.48.1
|
||||||
|
|
@ -28,6 +28,8 @@ URL: https://gtk.org
|
|||||||
Source0: https://download.gnome.org/sources/gtk+/3.24/gtk+-%{version}.tar.xz
|
Source0: https://download.gnome.org/sources/gtk+/3.24/gtk+-%{version}.tar.xz
|
||||||
|
|
||||||
Patch: 0001-testsuite-Stop-relying-on-xpms.patch
|
Patch: 0001-testsuite-Stop-relying-on-xpms.patch
|
||||||
|
Patch: 0001-Avoid-criticals-on-headless-systems.patch
|
||||||
|
|
||||||
BuildRequires: pkgconfig(atk) >= %{atk_version}
|
BuildRequires: pkgconfig(atk) >= %{atk_version}
|
||||||
BuildRequires: pkgconfig(atk-bridge-2.0)
|
BuildRequires: pkgconfig(atk-bridge-2.0)
|
||||||
BuildRequires: pkgconfig(avahi-gobject)
|
BuildRequires: pkgconfig(avahi-gobject)
|
||||||
@ -315,6 +317,8 @@ gtk-query-immodules-3.0-%{__isa_bits} --update-cache &>/dev/null || :
|
|||||||
* Mon Mar 10 2025 Matthias Clasen <mclasen@redhat.com> - 3.24.43-4
|
* Mon Mar 10 2025 Matthias Clasen <mclasen@redhat.com> - 3.24.43-4
|
||||||
- Stop relying on xpms in the testsuite
|
- Stop relying on xpms in the testsuite
|
||||||
Resolves: RHEL-69453
|
Resolves: RHEL-69453
|
||||||
|
- Avoid criticals on headless systems
|
||||||
|
Resolves: RHEL-40884
|
||||||
|
|
||||||
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 3.24.43-3
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 3.24.43-3
|
||||||
- Bump release for October 2024 mass rebuild:
|
- Bump release for October 2024 mass rebuild:
|
||||||
|
Loading…
Reference in New Issue
Block a user