summaryrefslogtreecommitdiffstats
path: root/patches/procps-3.2.8/30_pgrep_start_time.dpatch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/procps-3.2.8/30_pgrep_start_time.dpatch')
-rw-r--r--patches/procps-3.2.8/30_pgrep_start_time.dpatch36
1 files changed, 36 insertions, 0 deletions
diff --git a/patches/procps-3.2.8/30_pgrep_start_time.dpatch b/patches/procps-3.2.8/30_pgrep_start_time.dpatch
new file mode 100644
index 000000000..f68fd569e
--- /dev/null
+++ b/patches/procps-3.2.8/30_pgrep_start_time.dpatch
@@ -0,0 +1,36 @@
+#! /bin/sh -e
+## 30_pgrep_start_time.dpatch by Craig Small <csmall@debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: pgrep.c saved_start_time was missed
+
+[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
+patch_opts="${patch_opts:--f --no-backup-if-mismatch}"
+
+if [ $# -ne 1 ]; then
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+ exit 1
+fi
+case "$1" in
+ -patch) patch $patch_opts -p1 < $0;;
+ -unpatch) patch $patch_opts -p1 -R < $0;;
+ *)
+ echo >&2 "`basename $0`: script expects -patch|-unpatch as argum
+ent"
+ exit 1;;
+esac
+
+exit 0
+@DPATCH@
+--- procps-3.2.0.orig/pgrep.c
++++ procps-3.2.0/pgrep.c
+@@ -367,7 +367,8 @@
+ preg = do_regcomp ();
+
+ if (opt_newest) saved_start_time = 0ULL;
+- if (opt_oldest) saved_start_time = ~0ULL;
++ else
++ saved_start_time = ~0ULL;
+ if (opt_newest) saved_pid = 0;
+ if (opt_oldest) saved_pid = INT_MAX;
+