Author: Claus Assmann <sendmail-bugs-2017@support.sendmail.org>
Description: fix NOQUEUE: connect from (null)

--- a/sendmail/main.c
+++ b/sendmail/main.c
@@ -2623,8 +2623,19 @@ main(argc, argv, envp)
 
 	if (LogLevel > 9)
 	{
+		p = authinfo;
+		if (NULL == p)
+		{
+			if (NULL != RealHostName)
+				p = RealHostName;
+			else
+				p = anynet_ntoa(&RealHostAddr);
+			if (NULL == p)
+				p = "unknown";
+		}
+
 		/* log connection information */
-		sm_syslog(LOG_INFO, NULL, "connect from %s", authinfo);
+		sm_syslog(LOG_INFO, NULL, "connect from %s", p);
 	}
 
 	/*
