1 #include "sysutil.h" 2 #include <string.h> 3 4 /*=========================================================================* 5 * env_panic * 6 *=========================================================================*/ 7 void env_panic(const char *key) 8 { 9 static char value[EP_BUF_SIZE] = "<unknown>"; 10 int s; 11 if ((s=env_get_param(key, value, sizeof(value))) == 0) { 12 if (s != ESRCH) /* only error allowed */ 13 printf("WARNING: env_get_param() failed in env_panic(): %d\n", s); 14 } 15 panic("Bad environment setting: '%s = %s'\n", key, value); 16 } 17 18