* asn1_encode.c (asn1_encode_generaltime): Fixed the Mac code to
use the correct epoch.
* asn1_encode.c: Updated Utilities.h #include
[pullups from 1-2-2-branch]
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14561
dc483132-0cff-0310-8789-
dd5450dbe970
+2002-06-24 Alexandra Ellwood <lxs@mit.edu>
+
+ * asn1_encode.c: Removed unused Mac OS 9 code
+ [pullup from 1-2-2-branch]
+
+2000-06-24 Miro Jurisic <meeroh@mit.edu>
+
+ * asn1_encode.c (asn1_encode_generaltime): Fixed the Mac code to
+ use the correct epoch.
+
+ * asn1_encode.c: Updated Utilities.h #include
+
+ [pullups from 1-2-2-branch]
+
2002-06-24 Tom Yu <tlyu@mit.edu>
* asn1_get.c (asn1_get_length): Check for negative length.
return 0;
}
-#ifdef macintosh
-#define EPOCH ((70 * 365 * 24 * 60 * 60) + (17 * 24 * 60 * 60) + (getTimeZoneOffset() * 60 * 60))
-#else
-#define EPOCH (0)
-#endif
-
asn1_error_code asn1_encode_generaltime(buf, val, retlen)
asn1buf * buf;
const time_t val;
struct tm *gtime;
char s[16];
unsigned int length, sum=0;
- time_t gmt_time;
+ time_t gmt_time = val;
- gmt_time = val + EPOCH;
+#ifdef macintosh
+ unix_time_to_msl_time (&gmt_time);
+#endif
gtime = gmtime(&gmt_time);
/*