xfce4-session: fix xflock4

This commit is contained in:
Đoàn Trần Công Danh 2025-05-29 09:44:43 +07:00
parent 1829c706dd
commit 4a32d5b4c3
2 changed files with 35 additions and 1 deletions

View file

@ -0,0 +1,34 @@
From e084c7694554ad64462dd8675bb9fc466bb32ce7 Mon Sep 17 00:00:00 2001
From: Guido Falsi <mad@madpilot.net>
Date: Wed, 26 Mar 2025 09:55:05 +0100
Subject: [PATCH] Use syntax compatible with most sh shells.
The `**` syntax is a bash extension.
Reported by: Tijl Coosemans <tijl@FreeBSD.org> (patch also suggested by him)
---
scripts/xflock4 | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/xflock4 b/scripts/xflock4
index 45c2d063..d1f7cef9 100755
--- a/scripts/xflock4
+++ b/scripts/xflock4
@@ -47,12 +47,12 @@ esac
[ -t 0 ] && sleep 1
# echo is used to strip blanks
-# $((2**31 - 1)) is MAXINT, which disables timeout: see
+# $(((1<<31)-1)) is MAXINT, which disables timeout: see
# https://dbus.freedesktop.org/doc/api/html/group__DBusPendingCall.html
ret=$(echo $(dbus-send --session \
--dest=org.xfce.SessionManager \
--print-reply=literal \
- --reply-timeout=$((2**31 - 1)) \
+ --reply-timeout=$(((1<<31)-1)) \
--type=method_call \
/org/xfce/SessionManager \
org.xfce.Session.Manager.Lock))
--
GitLab

View file

@ -1,7 +1,7 @@
# Template file for 'xfce4-session'
pkgname=xfce4-session
version=4.20.2
revision=1
revision=2
build_style=gnu-configure
configure_args="--disable-static --enable-polkit"
hostmakedepends="pkg-config gettext glib-devel iceauth polkit"