!49 [sync] PR-44: ukui-settings-daemon-3.1.2-kylin-fix-coredump
From: @openeuler-sync-bot Reviewed-by: @peijiankang Signed-off-by: @peijiankang
This commit is contained in:
commit
c85d667c1d
59
ukui-settings-daemon-3.1.2-kylin-fix-coredump.patch
Normal file
59
ukui-settings-daemon-3.1.2-kylin-fix-coredump.patch
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
diff -Naur ukui-settings-daemon-3.1.2/daemon/main.cpp ukui-settings-daemon-3.1.2~/daemon/main.cpp
|
||||||
|
--- ukui-settings-daemon-3.1.2/daemon/main.cpp 2022-04-15 11:36:50.000000000 +0800
|
||||||
|
+++ ukui-settings-daemon-3.1.2~/daemon/main.cpp 2023-07-06 17:50:20.704690501 +0800
|
||||||
|
@@ -31,7 +31,8 @@
|
||||||
|
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <signal.h>
|
||||||
|
-
|
||||||
|
+#include <syslog.h>
|
||||||
|
+#include <QTimer>
|
||||||
|
static void print_help ();
|
||||||
|
static void parse_args (int argc, char *argv[]);
|
||||||
|
static void stop_daemon ();
|
||||||
|
@@ -46,6 +47,15 @@
|
||||||
|
QApplication::exit(15);
|
||||||
|
}
|
||||||
|
|
||||||
|
+void handlerA(int no)
|
||||||
|
+{
|
||||||
|
+ USD_LOG(LOG_DEBUG,"catch SIGABRT signal, with exitcode %d",no);
|
||||||
|
+
|
||||||
|
+
|
||||||
|
+// manager->managerStop();
|
||||||
|
+ QApplication::exit(15);
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
int main (int argc, char* argv[])
|
||||||
|
{
|
||||||
|
#if (QT_VERSION >= QT_VERSION_CHECK(5, 6, 0))
|
||||||
|
@@ -63,6 +73,7 @@
|
||||||
|
|
||||||
|
|
||||||
|
signal(SIGTERM, &handler);
|
||||||
|
+ signal(SIGABRT, &handlerA);
|
||||||
|
QApplication::setQuitOnLastWindowClosed(false);
|
||||||
|
|
||||||
|
QTranslator translator;
|
||||||
|
@@ -88,6 +99,21 @@
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
+ QObject::connect(&app,&QCoreApplication::aboutToQuit,[&]{
|
||||||
|
+
|
||||||
|
+ //PluginManager::getInstance()->managerStop();
|
||||||
|
+ //managerStop()执行时间过长,导致注销时,所有插件未完全Daectivity就已经强行关闭系统,最终导致SIGSEGV、SIGABRT
|
||||||
|
+
|
||||||
|
+ app.processEvents();
|
||||||
|
+ //QTimer timer;
|
||||||
|
+ // Wait until the event loop starts
|
||||||
|
+ QTimer::singleShot(500, [=](){
|
||||||
|
+
|
||||||
|
+ exit(0);
|
||||||
|
+ });
|
||||||
|
+
|
||||||
|
+ });
|
||||||
|
+
|
||||||
|
USD_LOG(LOG_INFO, "ukui-settings-daemon started!");
|
||||||
|
return app.exec();
|
||||||
|
}
|
||||||
@ -1,12 +1,13 @@
|
|||||||
Name: ukui-settings-daemon
|
Name: ukui-settings-daemon
|
||||||
Version: 3.1.2
|
Version: 3.1.2
|
||||||
Release: 4
|
Release: 5
|
||||||
Summary: daemon handling the UKUI session settings
|
Summary: daemon handling the UKUI session settings
|
||||||
License: GPL-2.0-or-later and GPL-3.0-or-later and LGPL-2.0-or-later
|
License: GPL-2.0-or-later and GPL-3.0-or-later and LGPL-2.0-or-later
|
||||||
URL: http://www.ukui.org
|
URL: http://www.ukui.org
|
||||||
Source0: %{name}-%{version}.tar.gz
|
Source0: %{name}-%{version}.tar.gz
|
||||||
Patch1: 0001-modify-compile-error-of-ukui-settings-daemon.patch
|
Patch1: 0001-modify-compile-error-of-ukui-settings-daemon.patch
|
||||||
Patch2: Fix-the-failure-of-shortcut-key-to-open-terminal.patch
|
Patch2: Fix-the-failure-of-shortcut-key-to-open-terminal.patch
|
||||||
|
Patch4: ukui-settings-daemon-3.1.2-kylin-fix-coredump.patch
|
||||||
|
|
||||||
BuildRequires: pkgconf-pkg-config
|
BuildRequires: pkgconf-pkg-config
|
||||||
BuildRequires: intltool
|
BuildRequires: intltool
|
||||||
@ -88,6 +89,7 @@ Summary: daemon handling the UKUI session settings (common files)
|
|||||||
%setup -q
|
%setup -q
|
||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
|
%patch4 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%{qmake_qt5}
|
%{qmake_qt5}
|
||||||
@ -133,6 +135,12 @@ glib-compile-schemas /usr/share/glib-2.0/schemas/ &> /dev/null || :
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Jul 10 2023 huayadong <huayadong@kylinos.cn> - 3.1.0-5
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add Patch4:ukui-settings-daemon-3.1.2-kylin-fix-coredump.patch
|
||||||
|
|
||||||
* Sun Jun 25 2023 peijiankang <peijiankang@kylinos.cn> - 3.1.2-4
|
* Sun Jun 25 2023 peijiankang <peijiankang@kylinos.cn> - 3.1.2-4
|
||||||
- Type:bugfix
|
- Type:bugfix
|
||||||
- ID:NA
|
- ID:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user