Added SILC Thread Queue API
[silc.git] / lib / silcutil / silctime.h
index cd9499c1d247264ce3877a999ce321c85e79ff4b..e01e1ae701f92660debb212b10dae7a6195f7b86 100644 (file)
@@ -44,7 +44,7 @@
  * SOURCE
  *
  ***/
-typedef struct {
+typedef struct SilcTimeObject {
   unsigned int year       : 15;           /* Year,     0 - 32768 */
   unsigned int month      : 4;    /* Month,    1 - 12 */
   unsigned int day        : 5;    /* Day,      1 - 31 */
@@ -247,17 +247,16 @@ SilcBool silc_time_generalized_string(SilcTime time_val, char *ret_string,
  *
  * SYNOPSIS
  *
- *    SilcBool silc_compare_timeval(struct time_val *smaller,
- *                                  struct time_val *bigger)
+ *    int silc_compare_timeval(struct time_val *t1, struct time_val *t2);
  *
  * DESCRIPTION
  *
- *    Compare two timeval structures and return TRUE if the first
- *    time value is smaller than the second time value.
+ *    Compares `t1' and `t2' time structures and returns less than zero,
+ *    zero or more than zero when `t1' is smaller, equal or bigger than
+ *    `t2', respectively.
  *
  ***/
-SilcBool silc_compare_timeval(struct timeval *smaller,
-                             struct timeval *bigger);
+int silc_compare_timeval(struct timeval *t1, struct timeval *t2);
 
 /****f* silcutil/SilcTimeAPI/silc_gettimeofday
  *
@@ -277,7 +276,7 @@ int silc_gettimeofday(struct timeval *p);
  *
  * SYNOPSIS
  *
- *    void silc_usleep(long microseconds);
+ *    void silc_usleep(unsigned long microseconds);
  *
  * DESCRIPTION
  *
@@ -291,7 +290,7 @@ int silc_gettimeofday(struct timeval *p);
  *
  ***/
 static inline
-void silc_usleep(long microseconds)
+void silc_usleep(unsigned long microseconds)
 {
 #ifdef SILC_UNIX
 #ifdef HAVE_NANOSLEEP
@@ -312,7 +311,7 @@ void silc_usleep(long microseconds)
   Sleep(microseconds / 1000);
 #endif /* SILC_WIN32 */
 #ifdef SILC_SYMBIAN
-  User::After(microseconds / 1000);
+  silc_symbian_usleep(microseconds);
 #endif /* SILC_SYMBIAN */
 }