Unit tests for formatting code, fix %%.
Also fix <signal.h> and <stdio.h> so they don't cause compiler warnings.
Change-Id: Ib1a746bf01de22d47dbd964de0e6af80a7c96303
diff --git a/libc/include/stdio.h b/libc/include/stdio.h
index cd04d9c..62882db 100644
--- a/libc/include/stdio.h
+++ b/libc/include/stdio.h
@@ -523,13 +523,13 @@
// Compiler can prove, at compile time, that the passed in size
// is always <= the actual object size. Don't call __fgets_chk
- if (__builtin_constant_p(size) && (size <= bos)) {
+ if (__builtin_constant_p(size) && (size <= (int) bos)) {
return __fgets_real(dest, size, stream);
}
// Compiler can prove, at compile time, that the passed in size
// is always > the actual object size. Force a compiler error.
- if (__builtin_constant_p(size) && (size > bos)) {
+ if (__builtin_constant_p(size) && (size > (int) bos)) {
__fgets_too_big_error();
}