+Thu Sep 7 12:00:00 1995 James Mattly <mattly@fusion.com>
+
+ * Renamed localaddr.c to c_localaddr.c because Mac can't have
+ two files with the same name.
+ * Makefile.in, .Sanitize updated for the above change.
+
Thu Aug 24 18:40:48 1995 Theodore Y. Ts'o <tytso@dcl>
* .Sanitize: Update file list
$(CC) $(CFLAGS) -c $(srcdir)/$*.c
@SHARED_RULE@
-OBJS= rnd_confoun.$(OBJEXT) localaddr.$(OBJEXT) ustime.$(OBJEXT) $(LIBOBJS)
+OBJS= rnd_confoun.$(OBJEXT) c_localaddr.$(OBJEXT) ustime.$(OBJEXT) $(LIBOBJS)
-SRCS= rnd_confoun.c localaddr.c ustime.c
+SRCS= rnd_confoun.c c_localaddr.c ustime.c
all:: all-$(WHAT)
#define NEED_SOCKETS
#include "k5-int.h"
-#ifdef HAVE_MACSOCK_H
+#ifdef _MACINTOSH
/* We're a Macintosh -- do Mac time things. */
/*
*******************************/
/* returns the offset in hours between the mac local time and the GMT */
-
-static
-unsigned krb5_int32
+/* unsigned krb5_int32 */
+krb5_int32
getTimeZoneOffset()
{
MachineLocation macLocation;
long gmtDelta;
- macLocation.gmtFlags.gmtDelta=0L;
+ macLocation.u.gmtDelta=0L;
ReadLocation(&macLocation);
- gmtDelta=macLocation.gmtFlags.gmtDelta & 0x00FFFFFF;
+ gmtDelta=macLocation.u.gmtDelta & 0x00FFFFFF;
if (BitTst((void *)&gmtDelta,23L)) gmtDelta |= 0xFF000000;
gmtDelta /= 3600L;
return(gmtDelta);
{
krb5_int32 sec, usec;
time_t the_time;
-
- GetDateTime (&the_time);
+ struct tm *gtime, *ltime;
+
+// GetDateTime (&the_time);
+ time(&the_time);
+// gtime = gmtime(&the_time);
+// ltime = localtime(&the_time);
sec = the_time -
((66 * 365 * 24 * 60 * 60) +
(17 * 24 * 60 * 60) +
*seconds = sec;
*microseconds = usec;
+
return 0;
}