the frozen config (with the wrong hostname)
SCCS-vsn: usr.sbin/sendmail/src/main.c 5.34
SCCS-vsn: usr.sbin/sendmail/src/version.c 5.73
#endif /* not lint */
#ifndef lint
#endif /* not lint */
#ifndef lint
-static char sccsid[] = "@(#)main.c 5.33 (Berkeley) %G%";
+static char sccsid[] = "@(#)main.c 5.34 (Berkeley) %G%";
#endif /* not lint */
#define _DEFINE
#endif /* not lint */
#define _DEFINE
bool queuemode = FALSE; /* process queue requests */
bool nothaw;
static bool reenter = FALSE;
bool queuemode = FALSE; /* process queue requests */
bool nothaw;
static bool reenter = FALSE;
- char jbuf[30]; /* holds MyHostName */
+ char jbuf[60]; /* holds MyHostName */
extern bool safefile();
extern time_t convtime();
extern putheader(), putbody();
extern bool safefile();
extern time_t convtime();
extern putheader(), putbody();
char *freezefile;
{
int f;
char *freezefile;
{
int f;
extern char edata, end;
extern char Version[];
extern caddr_t brk();
extern char edata, end;
extern char Version[];
extern caddr_t brk();
+ extern char **myhostname();
+ extern char *macvalue();
if (freezefile == NULL)
return (FALSE);
if (freezefile == NULL)
return (FALSE);
+
+ /* verify that the host name was correct on the freeze */
+ (void) myhostname(hbuf, sizeof hbuf);
+ p = macvalue('w', CurEnv);
+ if (p == NULL)
+ p = "";
+ if (strcmp(hbuf, macvalue('w', CurEnv)) == 0)
+ return (TRUE);
+ syslog(LOG_WARNING, "Hostname changed since freeze (%s => %s)",
+ p, hbuf);
+ return (FALSE);
}
\f/*
** DISCONNECT -- remove our connection with any foreground process
}
\f/*
** DISCONNECT -- remove our connection with any foreground process
-static char sccsid[] = "@(#)version.c 5.72 (Berkeley) %G%";
+static char sccsid[] = "@(#)version.c 5.73 (Berkeley) %G%";
-char Version[] = "5.72";
+char Version[] = "5.73";