From f948d6768b7554f3f4743e38c91c2bb283d8933c6600163fb313af35e52fbb34 Mon Sep 17 00:00:00 2001 From: Petr Cerny Date: Thu, 16 Aug 2012 12:55:50 +0000 Subject: [PATCH] Accepting request 130946 from home:elvigia:branches:network - When not daemonizing, such is used with systemd, no not create a PID file OBS-URL: https://build.opensuse.org/request/show/130946 OBS-URL: https://build.opensuse.org/package/show/network/openssh?expand=0&rev=35 --- openssh-nodaemon-nopid.patch | 11 +++++++++++ openssh.changes | 6 ++++++ openssh.spec | 2 ++ 3 files changed, 19 insertions(+) create mode 100644 openssh-nodaemon-nopid.patch diff --git a/openssh-nodaemon-nopid.patch b/openssh-nodaemon-nopid.patch new file mode 100644 index 0000000..14ba7d9 --- /dev/null +++ b/openssh-nodaemon-nopid.patch @@ -0,0 +1,11 @@ +--- sshd.c.orig ++++ sshd.c +@@ -1812,7 +1812,7 @@ main(int ac, char **av) + * Write out the pid file after the sigterm handler + * is setup and the listen sockets are bound + */ +- if (!debug_flag) { ++ if (!debug_flag || !no_daemon_flag) { + FILE *f = fopen(options.pid_file, "w"); + + if (f == NULL) { diff --git a/openssh.changes b/openssh.changes index 8569493..ebf962f 100644 --- a/openssh.changes +++ b/openssh.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Aug 15 19:25:08 UTC 2012 - crrodriguez@opensuse.org + +- When not daemonizing, such is used with systemd, no not + create a PID file + ------------------------------------------------------------------- Mon Jun 18 11:34:51 UTC 2012 - coolo@suse.com diff --git a/openssh.spec b/openssh.spec index d1ff6fe..9a75403 100644 --- a/openssh.spec +++ b/openssh.spec @@ -70,6 +70,7 @@ Patch18: %{name}-5.9p1-sshconfig-knownhostschanges.diff Patch19: %{name}-5.9p1-host_ident.diff Patch20: converter-linking.patch Patch21: openssh-nocrazyabicheck.patch +Patch22: openssh-nodaemon-nopid.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %if 0%{?suse_version} > 1140 BuildRequires: systemd @@ -109,6 +110,7 @@ also be forwarded over the secure channel. %patch19 -p1 %patch20 %patch21 +%patch22 cp -v %{SOURCE4} . cp -v %{SOURCE6} .