From ed69feaaff3c86745390c9839ecfc4b8f9706075 Mon Sep 17 00:00:00 2001
From: Alejandro Colomar <alx@kernel.org>
Date: Fri, 16 Dec 2022 01:08:12 +0100
Subject: [PATCH] Fix typos in length calculations

Link: <https://github.com/shadow-maint/shadow/pull/607>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
---
 src/groupmod.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/groupmod.c b/src/groupmod.c
index 7802e5b1..8c219194 100644
--- a/src/groupmod.c
+++ b/src/groupmod.c
@@ -578,11 +578,11 @@ static void prepare_failure_reports (void)
 	                 group_name, (unsigned long int) group_id);
 #ifdef	SHADOWGRP
 	(void) snprintf (info_gshadow.action,
-	                 512 - strlen (info_group.audit_msg),
+	                 512 - strlen (info_gshadow.audit_msg),
 	                 "group %s", group_name);
 #endif
 	(void) snprintf (info_passwd.action,
-	                 512 - strlen (info_group.audit_msg),
+	                 512 - strlen (info_passwd.audit_msg),
 	                 "group %s/%lu",
 	                 group_name, (unsigned long int) group_id);
 
-- 
2.27.0

