Index: kernel/generic/src/console/console.c
===================================================================
--- kernel/generic/src/console/console.c	(revision a7b10710077af5495dbbd8a18f1fb413be7dc5c2)
+++ kernel/generic/src/console/console.c	(revision 171f9a1fe9f611d6f72a49a47ddb0eaefd93ccbd)
@@ -54,8 +54,9 @@
 
 #define KLOG_SIZE     PAGE_SIZE
+#define KLOG_LENGTH   (KLOG_SIZE / sizeof(wchar_t))
 #define KLOG_LATENCY  8
 
 /** Kernel log cyclic buffer */
-static wchar_t klog[KLOG_SIZE] __attribute__ ((aligned (PAGE_SIZE)));
+static wchar_t klog[KLOG_LENGTH] __attribute__ ((aligned (PAGE_SIZE)));
 
 /** Kernel log initialized */
@@ -258,14 +259,14 @@
 		index_t i;
 		for (i = klog_len - klog_stored; i < klog_len; i++)
-			stdout->op->write(stdout, klog[(klog_start + i) % KLOG_SIZE], silent);
+			stdout->op->write(stdout, klog[(klog_start + i) % KLOG_LENGTH], silent);
 		klog_stored = 0;
 	}
 	
 	/* Store character in the cyclic kernel log */
-	klog[(klog_start + klog_len) % KLOG_SIZE] = ch;
-	if (klog_len < KLOG_SIZE)
+	klog[(klog_start + klog_len) % KLOG_LENGTH] = ch;
+	if (klog_len < KLOG_LENGTH)
 		klog_len++;
 	else
-		klog_start = (klog_start + 1) % KLOG_SIZE;
+		klog_start = (klog_start + 1) % KLOG_LENGTH;
 	
 	if ((stdout) && (stdout->op->write))
