More ANSI/ISO 9899-1990 to the people!
Now actually builds (not including util) with DEC "cc -std1" and Sun "acc -Xc". There are still major prototype conflicts, but there isn't much to do about this. git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@192 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -72,6 +72,25 @@ des_new_random_key(des_cblock *key)
|
||||
return(0);
|
||||
}
|
||||
|
||||
/* this is for broken Solaris */
|
||||
#ifndef HAVE_GETHOSTID
|
||||
|
||||
#include <sys/systeminfo.h>
|
||||
|
||||
static long gethostid(void)
|
||||
{
|
||||
static int flag=0;
|
||||
static long hostid;
|
||||
if(!flag){
|
||||
char s[32];
|
||||
sysinfo(SI_HW_SERIAL, s, 32);
|
||||
sscanf(s, "%u", &hostid);
|
||||
flag=1;
|
||||
}
|
||||
return hostid;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
* des_init_random_number_generator:
|
||||
*
|
||||
|
Reference in New Issue
Block a user