Index: boot/generic/src/str.c
===================================================================
--- boot/generic/src/str.c	(revision 10d65d70906a865fb116576edc88e47ab61a5fb4)
+++ boot/generic/src/str.c	(revision fc448f5f560ea1a9a7e90a7dff181e501713aa1e)
@@ -1,4 +1,8 @@
 /*
  * Copyright (c) 2001-2004 Jakub Jermar
+ * Copyright (c) 2005 Martin Decky
+ * Copyright (c) 2008 Jiri Svoboda
+ * Copyright (c) 2011 Martin Sucha
+ * Copyright (c) 2011 Oleg Romanenko
  * All rights reserved.
  *
@@ -98,9 +102,10 @@
  */
 
+#include <str.h>
+
 #include <errno.h>
 #include <stdbool.h>
 #include <stddef.h>
 #include <stdint.h>
-#include <str.h>
 
 /** Check the condition if wchar_t is signed */
@@ -208,5 +213,5 @@
  *         code was invalid.
  */
-int chr_encode(const wchar_t ch, char *str, size_t *offset, size_t size)
+errno_t chr_encode(const wchar_t ch, char *str, size_t *offset, size_t size)
 {
 	if (*offset >= size)
@@ -392,5 +397,5 @@
 			return 1;
 
-		if ((c1 == 0) || (c2 == 0))
+		if (c1 == 0 || c2 == 0)
 			break;
 	}
