mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-02-04 05:27:15 +08:00
kdebase-workspace: add null pointer crash patch
This commit is contained in:
parent
2fb39fff0e
commit
3b407ee7ea
@ -26,7 +26,7 @@ pkgname=('kdebase-workspace'
|
|||||||
|
|
||||||
arch=('i686' 'x86_64')
|
arch=('i686' 'x86_64')
|
||||||
pkgver=${_kdever}
|
pkgver=${_kdever}
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
|
|
||||||
pkgdesc="split package"
|
pkgdesc="split package"
|
||||||
url="http://www.kde.org"
|
url="http://www.kde.org"
|
||||||
@ -78,7 +78,7 @@ source=($_mirror/${_origname}-$_kdever.tar.bz2
|
|||||||
fix_kdm_configdef.patch
|
fix_kdm_configdef.patch
|
||||||
|
|
||||||
# "fix" some sytemsettings modules that need root access
|
# "fix" some sytemsettings modules that need root access
|
||||||
fix_root-only-kcms.patch)
|
fix_root-only-kcms.patch
|
||||||
|
|
||||||
# fix powerdevil
|
# fix powerdevil
|
||||||
# trunk_powerdevil.patch
|
# trunk_powerdevil.patch
|
||||||
@ -96,6 +96,8 @@ source=($_mirror/${_origname}-$_kdever.tar.bz2
|
|||||||
# feature_history-notifications-enable-disable-kde#119207.patch
|
# feature_history-notifications-enable-disable-kde#119207.patch
|
||||||
|
|
||||||
# feature_kdm-plymouth.patch
|
# feature_kdm-plymouth.patch
|
||||||
|
fix-null-pointer-crash.patch
|
||||||
|
)
|
||||||
|
|
||||||
md5sums=(`grep ${_origname}-$_kdever.tar.bz2 ../kde-sc.md5 | cut -d" " -f1`
|
md5sums=(`grep ${_origname}-$_kdever.tar.bz2 ../kde-sc.md5 | cut -d" " -f1`
|
||||||
'f355a658d2e9267fdf4e8d8f88038bcf' # mishaaq-kcm_touchpad-00370b5.tar.gz
|
'f355a658d2e9267fdf4e8d8f88038bcf' # mishaaq-kcm_touchpad-00370b5.tar.gz
|
||||||
@ -121,7 +123,7 @@ md5sums=(`grep ${_origname}-$_kdever.tar.bz2 ../kde-sc.md5 | cut -d" " -f1`
|
|||||||
'814350c52c135d6f7bdada1e29223d38' # fix_terminate-server.patch
|
'814350c52c135d6f7bdada1e29223d38' # fix_terminate-server.patch
|
||||||
# '5d752cf39a28306438bb6d82db6e1696'# fix_ck-shutdown.patch
|
# '5d752cf39a28306438bb6d82db6e1696'# fix_ck-shutdown.patch
|
||||||
'97a5eb51e6f9d460f0d61bb322a1db5e' # fix_kdm_configdef.patch
|
'97a5eb51e6f9d460f0d61bb322a1db5e' # fix_kdm_configdef.patch
|
||||||
'5f963f80a026f0600edae1b1c70411e5') # fix_root-only-kcms.patch
|
'5f963f80a026f0600edae1b1c70411e5' # fix_root-only-kcms.patch
|
||||||
|
|
||||||
# 'c6b58eb228d16c77d692df655046ee9f' # trunk_powerdevil.patch
|
# 'c6b58eb228d16c77d692df655046ee9f' # trunk_powerdevil.patch
|
||||||
|
|
||||||
@ -131,6 +133,8 @@ md5sums=(`grep ${_origname}-$_kdever.tar.bz2 ../kde-sc.md5 | cut -d" " -f1`
|
|||||||
# '894815a80f99a9a0dee1adbcda49b161' # feature_battery-tooltip.patch
|
# '894815a80f99a9a0dee1adbcda49b161' # feature_battery-tooltip.patch
|
||||||
# '9b97ac1b4deb8d0c8ca7afffb80b4320' # feature_history-notifications-enable-disable-kde#119207.patch
|
# '9b97ac1b4deb8d0c8ca7afffb80b4320' # feature_history-notifications-enable-disable-kde#119207.patch
|
||||||
# '42b3b5e09372c57910c3435e63e2dfd6' # feature_kdm-plymouth.patch
|
# '42b3b5e09372c57910c3435e63e2dfd6' # feature_kdm-plymouth.patch
|
||||||
|
'2f106f7451463b45e17811c4a29d2744' # fix-null-pointer-crash.patch
|
||||||
|
)
|
||||||
|
|
||||||
#
|
#
|
||||||
# build function
|
# build function
|
||||||
@ -176,8 +180,8 @@ build()
|
|||||||
# patch -Np1 -i ${srcdir}/feature_history-notifications-enable-disable-kde#119207.patch || return 1
|
# patch -Np1 -i ${srcdir}/feature_history-notifications-enable-disable-kde#119207.patch || return 1
|
||||||
# patch -Np1 -i ${srcdir}/feature_kdm-plymouth.patch || return 1
|
# patch -Np1 -i ${srcdir}/feature_kdm-plymouth.patch || return 1
|
||||||
|
|
||||||
# msg "applying chakra patches ..."
|
msg "applying upstream patches ..."
|
||||||
|
patch -Np1 -i ${srcdir}/fix-null-pointer-crash.patch || return 1
|
||||||
|
|
||||||
msg "starting workspace build ..."
|
msg "starting workspace build ..."
|
||||||
cmake . -DCMAKE_BUILD_TYPE=${_build_type} \
|
cmake . -DCMAKE_BUILD_TYPE=${_build_type} \
|
||||||
|
34
kdebase-workspace/fix-null-pointer-crash.patch
Normal file
34
kdebase-workspace/fix-null-pointer-crash.patch
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
From: Andriy Rysin <arysin@gmail.com>
|
||||||
|
Date: Sun, 03 Apr 2011 02:27:37 +0000
|
||||||
|
Subject: Fix null pointer crash when no rules found; add unit test
|
||||||
|
X-Git-Url: http://quickgit.kde.org/?p=kde-workspace.git&a=commitdiff&h=754b4aee80ef521433c8179bca122c22135f5118
|
||||||
|
---
|
||||||
|
Fix null pointer crash when no rules found; add unit test
|
||||||
|
BUG: 269961
|
||||||
|
---
|
||||||
|
|
||||||
|
|
||||||
|
--- a/kcontrol/keyboard/flags.cpp
|
||||||
|
+++ b/kcontrol/keyboard/flags.cpp
|
||||||
|
@@ -136,7 +136,7 @@ static QString getDisplayText(const QStr
|
||||||
|
{
|
||||||
|
if( variant.isEmpty() )
|
||||||
|
return layout;
|
||||||
|
- if( rules->version == "1.0" )
|
||||||
|
+ if( rules == NULL || rules->version == "1.0" )
|
||||||
|
return i18nc("layout - variant", "%1 - %2", layout, variant);
|
||||||
|
return variant;
|
||||||
|
}
|
||||||
|
|
||||||
|
--- a/kcontrol/keyboard/tests/flags_test.cpp
|
||||||
|
+++ b/kcontrol/keyboard/tests/flags_test.cpp
|
||||||
|
@@ -82,6 +82,9 @@ private Q_SLOTS:
|
||||||
|
QVERIFY( flags->getLongText(layoutUnit1, rules).startsWith("USA - International") );
|
||||||
|
QCOMPARE( flags->getLongText(layoutUnit2, rules), QString("USA - other") );
|
||||||
|
|
||||||
|
+ rules = NULL; // when no rules found
|
||||||
|
+ QCOMPARE( flags->getLongText(layoutUnit1, rules), QString("us - intl") );
|
||||||
|
+
|
||||||
|
flags->clearCache();
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user