diff options
author | 2010-12-02 21:53:04 +0000 | |
---|---|---|
committer | 2010-12-02 21:53:04 +0000 | |
commit | 61582b6dae979427599c8b73527e5ba99c7b86d6 (patch) | |
tree | af2bc19b6b569f3965ab74dcbeff0e4fe3751d8b /net-analyzer/fail2ban/files | |
parent | Install pc files for threads (diff) | |
download | gentoo-2-61582b6dae979427599c8b73527e5ba99c7b86d6.tar.gz gentoo-2-61582b6dae979427599c8b73527e5ba99c7b86d6.tar.bz2 gentoo-2-61582b6dae979427599c8b73527e5ba99c7b86d6.zip |
Create /var/run/fail2ban on runtime and remove stalled sock file in case of system crash. Thanks to Michael Lorant <mikel@mlvision.com.au>. Bug #347477. Taking over maintainership
(Portage version: 2.2.0_alpha6/cvs/Linux x86_64)
Diffstat (limited to 'net-analyzer/fail2ban/files')
-rw-r--r-- | net-analyzer/fail2ban/files/gentoo-initd_create_run_dir.patch | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/net-analyzer/fail2ban/files/gentoo-initd_create_run_dir.patch b/net-analyzer/fail2ban/files/gentoo-initd_create_run_dir.patch new file mode 100644 index 000000000000..79a947956e37 --- /dev/null +++ b/net-analyzer/fail2ban/files/gentoo-initd_create_run_dir.patch @@ -0,0 +1,19 @@ +Index: fail2ban-0.8.4/files/gentoo-initd +=================================================================== +--- fail2ban-0.8.4.orig/files/gentoo-initd ++++ fail2ban-0.8.4/files/gentoo-initd +@@ -31,6 +31,14 @@ depend() { + + start() { + ebegin "Starting fail2ban" ++ if [ ! -d /var/run/fail2ban ]; then ++ mkdir /var/run/fail2ban || return 1 ++ fi ++ if [ -e /var/run/fail2ban/fail2ban.sock ]; then ++ # remove stalled sock file after system crash ++ # bug 347477 ++ rm -rf /var/run/fail2ban/fail2ban.sock || return 1 ++ fi + ${FAIL2BAN} start &> /dev/null + eend $? "Failed to start fail2ban" + } |