Cleanup: fix various int/long format string errors.
authorKp <kp@valhallalegends.com>
Mon, 8 Dec 2008 00:59:23 +0000 (18:59 -0600)
committerKp <kp@valhallalegends.com>
Sat, 13 Dec 2008 19:57:37 +0000 (13:57 -0600)
Various format strings used int values with long format specifiers.
Fix the format specifiers to be consistent with the values supplied.

apps/irssi/src/silc/core/client_ops.c
apps/silcd/serverconfig.c
lib/silcske/silcske.c
lib/silcutil/silcschedule.c
lib/silcutil/unix/silcunixschedule.c

index 16feddc7583a8b2c18dd200f736473b2a8ba6d92..cfefe3275300b7e98db354c1ec378c3128b751b9 100644 (file)
@@ -1677,7 +1677,7 @@ void silc_command_reply(SilcClient client, SilcClientConnection conn,
 
       if (idle && nickname) {
        memset(buf, 0, sizeof(buf));
-       snprintf(buf, sizeof(buf) - 1, "%lu %s",
+       snprintf(buf, sizeof(buf) - 1, "%u %s",
                 idle > 60 ? (idle / 60) : idle,
                 idle > 60 ? "minutes" : "seconds");
 
index 30d76af3516cae4c81cbb60a718e938cc66fadf3..a2c589235bc7bfb28ffaee10f62c3f1706815d07 100644 (file)
@@ -1542,7 +1542,7 @@ SilcServerConfig silc_server_config_alloc(const char *filename,
                               silc_config_strerror(ret)));
       linebuf = silc_config_read_line(file, line);
       if (linebuf) {
-       SILC_SERVER_LOG_ERROR(("  file %s line %lu:  %s\n", filename,
+       SILC_SERVER_LOG_ERROR(("  file %s line %u:  %s\n", filename,
                               line, linebuf));
        silc_free(linebuf);
       }
index a4822e95a505a8cb709d6d63bfb0f4eabf9e8f0f..5cb7c91d9c7f908aa8313d2cb6e3383165f079cf 100644 (file)
@@ -80,7 +80,7 @@ static SilcBool silc_ske_packet_send(SilcSKE ske,
  */
 static void silc_ske_notify_failure(SilcSKE ske)
 {
-  SILC_LOG_DEBUG(("Notifying SKE %p owner of failure (failure_notified = %lu)",
+  SILC_LOG_DEBUG(("Notifying SKE %p owner of failure (failure_notified = %d)",
                  ske, ske->failure_notified));
 
   /*
index 6c2f78ca840ed05982bcd56591f76b9809223f3a..31168d307d8a65701b38292f7e0b9e2cc8a05e2a 100644 (file)
@@ -290,7 +290,7 @@ void silc_schedule_stats(SilcSchedule schedule)
 {
   SilcTaskFd ftask;
   fprintf(stdout, "Schedule %p statistics:\n\n", schedule);
-  fprintf(stdout, "Num FD tasks         : %lu (%lu bytes allocated)\n",
+  fprintf(stdout, "Num FD tasks         : %u (%u bytes allocated)\n",
          silc_hash_table_count(schedule->fd_queue),
          sizeof(*ftask) * silc_hash_table_count(schedule->fd_queue));
   fprintf(stdout, "Num Timeout tasks    : %d (%d bytes allocated)\n",
index 80e8fbf264e9a471a1732ef98b1c3c7546f8f65e..bcbe120331cdca96dcad834c4250dc95c55e8c49 100644 (file)
@@ -274,7 +274,7 @@ SilcBool silc_schedule_internal_schedule_fd(SilcSchedule schedule,
   if (!internal)
     return TRUE;
 
-  SILC_LOG_DEBUG(("Scheduling fd %lu, mask %x", task->fd, event_mask));
+  SILC_LOG_DEBUG(("Scheduling fd %u, mask %x", task->fd, event_mask));
 
   memset(&event, 0, sizeof(event));
   if (event_mask & SILC_TASK_READ)