Initial revision

This commit is contained in:
Ben Gras
2005-04-21 14:53:53 +00:00
commit 9865aeaa79
2264 changed files with 411685 additions and 0 deletions

19
lib/utils/env_panic.c Normal file
View File

@@ -0,0 +1,19 @@
#include "utils.h"
#include <string.h>
/*=========================================================================*
* env_panic *
*=========================================================================*/
PUBLIC void env_panic(key)
char *key; /* environment variable whose value is bogus */
{
static char value[EP_BUF_SIZE] = "<unknown>";
int s;
if ((s=sys_getkenv(key, strlen(key), value, sizeof(value))) == 0) {
if (s != ESRCH) /* only error allowed */
printf("WARNING: sys_getkenv() failed in env_panic(): %d\n", s);
}
printf("Bad environment setting: '%s = %s'\n", key, value);
server_panic("","", NO_NUM);
}