git: a12f8e45854d - main - x11/xfce4-screensaver: Update patch to upstream version
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 23 Dec 2025 12:06:15 UTC
The branch main has been updated by madpilot:
URL: https://cgit.FreeBSD.org/ports/commit/?id=a12f8e45854d6aae92460f14a61a3f2c211bf06f
commit a12f8e45854d6aae92460f14a61a3f2c211bf06f
Author: Guido Falsi <madpilot@FreeBSD.org>
AuthorDate: 2025-12-23 12:03:36 +0000
Commit: Guido Falsi <madpilot@FreeBSD.org>
CommitDate: 2025-12-23 12:03:36 +0000
x11/xfce4-screensaver: Update patch to upstream version
Obtained from: https://gitlab.xfce.org/apps/xfce4-screensaver/-/merge_requests/59
---
x11/xfce4-screensaver/Makefile | 2 +-
.../files/patch-src_gs-lock-plug.c | 37 ++++++++++------------
2 files changed, 18 insertions(+), 21 deletions(-)
diff --git a/x11/xfce4-screensaver/Makefile b/x11/xfce4-screensaver/Makefile
index a6e24c94a9fe..2138ca1a5abd 100644
--- a/x11/xfce4-screensaver/Makefile
+++ b/x11/xfce4-screensaver/Makefile
@@ -1,6 +1,6 @@
PORTNAME= xfce4-screensaver
PORTVERSION= 4.20.1
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= x11 xfce
MASTER_SITES= XFCE/apps
DIST_SUBDIR= xfce4
diff --git a/x11/xfce4-screensaver/files/patch-src_gs-lock-plug.c b/x11/xfce4-screensaver/files/patch-src_gs-lock-plug.c
index 30e2facb44a6..374c4f11525e 100644
--- a/x11/xfce4-screensaver/files/patch-src_gs-lock-plug.c
+++ b/x11/xfce4-screensaver/files/patch-src_gs-lock-plug.c
@@ -1,18 +1,4 @@
-From 5a6b01aaeb109ef419ab021972a4225618b277ce Mon Sep 17 00:00:00 2001
-From: Guido Falsi <madpilot@freebsd.org>
-Date: Sun, 16 Nov 2025 12:14:37 +0100
-Subject: [PATCH] Use pgrep in place of pidof
-
-This also simplifies function logic.
-
-Fixes: #38
----
- src/gs-lock-plug.c | 16 ++++------------
- 1 file changed, 4 insertions(+), 12 deletions(-)
-
-diff --git a/src/gs-lock-plug.c b/src/gs-lock-plug.c
-index d0806f64..fce7bf15 100644
---- src/gs-lock-plug.c
+--- src/gs-lock-plug.c.orig 2025-08-15 14:02:14 UTC
+++ src/gs-lock-plug.c
@@ -26,6 +26,7 @@
#include <stdlib.h>
@@ -22,14 +8,28 @@ index d0806f64..fce7bf15 100644
#include <time.h>
#include <unistd.h>
-@@ -179,20 +180,11 @@ toggle_infobar_visibility (GSLockPlug *plug) {
+@@ -56,6 +57,8 @@
+ #include "xfce-bg.h"
+ #include "xfce-desktop-utils.h"
+
++#define PGREP_MAX_PROCESS_LEN 15
++
+ #define MDM_FLEXISERVER_COMMAND "mdmflexiserver"
+ #define MDM_FLEXISERVER_ARGS "--startnew Standard"
+
+@@ -179,20 +182,16 @@ process_is_running (const char *name) {
static gboolean
process_is_running (const char *name) {
- int num_processes;
- gchar *command = g_strdup_printf ("pidof %s | wc -l", name);
- FILE *fp = popen (command, "r");
-+ gchar *command = g_strdup_printf ("pgrep -a %s", name);
++ g_return_val_if_fail (strnlen (name, PGREP_MAX_PROCESS_LEN + 1) > PGREP_MAX_PROCESS_LEN, FALSE);
++#ifdef __FreeBSD__
++ gchar *command = g_strdup_printf ("pgrep -ax %s", name);
++#else
++ gchar *command = g_strdup_printf ("pgrep -x %s", name);
++#endif
+ int rc = system (command);
g_free (command);
@@ -46,6 +46,3 @@ index d0806f64..fce7bf15 100644
return TRUE;
} else {
return FALSE;
---
-GitLab
-