Added SILC Thread Queue API
[silc.git] / lib / silcutil / tests / test_silctime.c
index bcfa713ebd44e839aafd8f978d19a9d060023858..d269eb60fccf550fb1683870a3f2ecaa0acc24b2 100644 (file)
@@ -6,12 +6,13 @@ int main(int argc, char **argv)
 {
   SilcBool success = FALSE;
   SilcTimeStruct curtime;
+  unsigned char ts[32];
 
   if (argc > 1 && !strcmp(argv[1], "-d")) {
     silc_log_debug(TRUE);
     silc_log_quick(TRUE);
     silc_log_debug_hexdump(TRUE);
-    silc_log_set_debug_string("*time*");
+    silc_log_set_debug_string("*time*,*errno*");
   }
 
   SILC_LOG_DEBUG(("Get current time"));
@@ -29,6 +30,11 @@ int main(int argc, char **argv)
   SILC_LOG_DEBUG(("utc_east  : %d", curtime.utc_east));
   SILC_LOG_DEBUG(("dst       : %d", curtime.dst));
 
+  silc_time_universal_string(&curtime, ts, sizeof(ts));
+  SILC_LOG_DEBUG(("Universal: %s", ts));
+  silc_time_generalized_string(&curtime, ts, sizeof(ts));
+  SILC_LOG_DEBUG(("Generaliz: %s", ts));
+
   success = TRUE;
 
  err: