forked from pool/hugin
Accepting request 1033007 from graphics
- Add xdg-data.patch: fixes bsc#1204546 (forwarded request 1032873 from polslinux) OBS-URL: https://build.opensuse.org/request/show/1033007 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/hugin?expand=0&rev=76
This commit is contained in:
commit
65451f1b94
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 2 12:29:44 UTC 2022 - Paolo Stivanin <info@paolostivanin.com>
|
||||
|
||||
- Add xdg-data.patch: fixes bsc#1204546
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Oct 17 07:41:24 UTC 2022 - pgajdos@suse.com
|
||||
|
||||
|
@ -31,6 +31,7 @@ Group: Productivity/Graphics/Other
|
||||
URL: http://hugin.sourceforge.net/
|
||||
Source: https://downloads.sourceforge.net/project/%{name}/%{name}/%{name}-%{mversion}/%{name}-%{version}.tar.bz2
|
||||
Patch0: hugin.appdata.patch
|
||||
Patch1: xdg-data.patch
|
||||
BuildRequires: Mesa-devel
|
||||
BuildRequires: OpenEXR-devel
|
||||
BuildRequires: cmake >= 3.1.0
|
||||
|
23
xdg-data.patch
Normal file
23
xdg-data.patch
Normal file
@ -0,0 +1,23 @@
|
||||
# HG changeset patch
|
||||
# User tmodes
|
||||
# Date 1658245150 -7200
|
||||
# Tue Jul 19 17:39:10 2022 +0200
|
||||
# Node ID edfddc6070ca6d4223d359fb4b38273a5aed2f2d
|
||||
# Parent 490baa16aae6680792d31316be12a75b50236baa
|
||||
Fixes crash when environment variable XDG_DATA_HOME is not set
|
||||
|
||||
diff -r 490baa16aae6 -r edfddc6070ca src/hugin_base/hugin_utils/utils.cpp
|
||||
--- a/src/hugin_base/hugin_utils/utils.cpp Thu May 26 18:58:52 2022 +0200
|
||||
+++ b/src/hugin_base/hugin_utils/utils.cpp Tue Jul 19 17:39:10 2022 +0200
|
||||
@@ -472,9 +472,9 @@
|
||||
#else
|
||||
#ifdef USE_XDG_DIRS
|
||||
char *xdgDataDir = getenv("XDG_DATA_HOME");
|
||||
- if (strlen(xdgDataDir) == 0)
|
||||
+ if (xdgDataDir == NULL || strlen(xdgDataDir) == 0)
|
||||
{
|
||||
- // no XDG_DATA_HOME enviroment variable set
|
||||
+ // no XDG_DATA_HOME enviroment variable set or empty variable
|
||||
// use $HOME/.local/share instead
|
||||
const std::string homeDir = GetHomeDir();
|
||||
if (homeDir.empty())
|
Loading…
Reference in New Issue
Block a user