summaryrefslogtreecommitdiffstats
path: root/debian/patches/debian/0003-host-name-in-default-mailfrom.patch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-10 20:55:45 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-10 20:55:45 +0000
commit2c958b35ba11c61dd2b7416d2f6067655512d2b9 (patch)
tree4beee0533c06469c7d12d2493f59b0add009c75e /debian/patches/debian/0003-host-name-in-default-mailfrom.patch
parentAdding upstream version 4.3. (diff)
downloadmdadm-2c958b35ba11c61dd2b7416d2f6067655512d2b9.tar.xz
mdadm-2c958b35ba11c61dd2b7416d2f6067655512d2b9.zip
Adding debian version 4.3-1.debian/4.3-1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches/debian/0003-host-name-in-default-mailfrom.patch')
-rw-r--r--debian/patches/debian/0003-host-name-in-default-mailfrom.patch17
1 files changed, 17 insertions, 0 deletions
diff --git a/debian/patches/debian/0003-host-name-in-default-mailfrom.patch b/debian/patches/debian/0003-host-name-in-default-mailfrom.patch
new file mode 100644
index 0000000..870e9d4
--- /dev/null
+++ b/debian/patches/debian/0003-host-name-in-default-mailfrom.patch
@@ -0,0 +1,17 @@
+Author: Felix Lechner <felix.lechner@lease-up.com>
+Description: Add host name to default MAILFROM (Closes: #1006464).
+ The host on which the error occurred is mentioned in the subject and also in
+ the message body, but some may find it useful in the From address, as well.
+
+diff -Naurp mdadm.orig/Monitor.c mdadm/Monitor.c
+--- mdadm.orig/Monitor.c
++++ mdadm/Monitor.c
+@@ -627,7 +627,7 @@ static void send_event_email(const struc
+ if (info.mailfrom)
+ fprintf(mp, "From: %s\n", info.mailfrom);
+ else
+- fprintf(mp, "From: %s monitoring <root>\n", Name);
+++ fprintf(mp, "From: %s monitoring <root@%s>\n", Name, info.hostname);
+ fprintf(mp, "To: %s\n", info.mailaddr);
+ fprintf(mp, "Subject: %s event on %s:%s\n\n", data->event_name, data->dev, info.hostname);
+ fprintf(mp, "This is an automatically generated mail message.\n");