diff options
author | danilo <danilo@FreeBSD.org> | 2016-02-16 07:14:37 +0800 |
---|---|---|
committer | danilo <danilo@FreeBSD.org> | 2016-02-16 07:14:37 +0800 |
commit | c7228425fd19d0774b929053da15694a68f64544 (patch) | |
tree | 9289111d797ce37af50509a7a7468e237f706e2a /games | |
parent | a0516c85a93a375b6e10c7d196c479c200ab7239 (diff) | |
download | freebsd-ports-graphics-c7228425fd19d0774b929053da15694a68f64544.tar.gz freebsd-ports-graphics-c7228425fd19d0774b929053da15694a68f64544.tar.zst freebsd-ports-graphics-c7228425fd19d0774b929053da15694a68f64544.zip |
- Fix crash when there's no xrandr support
PR: 207113
Submitted by: amdmi3
Diffstat (limited to 'games')
-rw-r--r-- | games/doomsday/Makefile | 1 | ||||
-rw-r--r-- | games/doomsday/files/patch-doomsday_libgui_src_displaymode__x11.cpp | 16 |
2 files changed, 17 insertions, 0 deletions
diff --git a/games/doomsday/Makefile b/games/doomsday/Makefile index 7b6496e49bc..77257cbaceb 100644 --- a/games/doomsday/Makefile +++ b/games/doomsday/Makefile @@ -3,6 +3,7 @@ PORTNAME= doomsday PORTVERSION= 1.15.8 +PORTREVISION= 1 CATEGORIES= games MASTER_SITES= SF/deng/Doomsday%20Engine/${PORTVERSION} DISTNAME= ${PORTNAME}-stable-${PORTVERSION} diff --git a/games/doomsday/files/patch-doomsday_libgui_src_displaymode__x11.cpp b/games/doomsday/files/patch-doomsday_libgui_src_displaymode__x11.cpp new file mode 100644 index 00000000000..871104c7e12 --- /dev/null +++ b/games/doomsday/files/patch-doomsday_libgui_src_displaymode__x11.cpp @@ -0,0 +1,16 @@ +--- doomsday/libgui/src/displaymode_x11.cpp.orig 2016-02-01 03:37:12 UTC ++++ doomsday/libgui/src/displaymode_x11.cpp +@@ -54,8 +54,12 @@ public: + /** + * Queries all the available modes in the display configuration. + */ +- RRInfo() : _numSizes(0) ++ RRInfo() : _conf(NULL), _numSizes(0) + { ++ int dummy; ++ if (!XRRQueryExtension(QX11Info::display(), &dummy, &dummy)) ++ return; // Not available. ++ + _conf = XRRGetScreenInfo(QX11Info::display(), QX11Info::appRootWindow()); + if(!_conf) return; // Not available. + |