aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorMarco Paland <marco@paland.com>2017-10-31 13:49:28 +0100
committerMarco Paland <marco@paland.com>2017-10-31 13:49:28 +0100
commit5813e52e3f08ca1c4bb4e4ea41e03ce787ac25c8 (patch)
treef32fa0d2b1bea0f549557a2d4c09d395cee82145 /README.md
parente50beaa69ea4832dd984fef2e4c297df3495801b (diff)
downloadprintf-5813e52e3f08ca1c4bb4e4ea41e03ce787ac25c8.tar.gz
printf-5813e52e3f08ca1c4bb4e4ea41e03ce787ac25c8.tar.bz2
printf-5813e52e3f08ca1c4bb4e4ea41e03ce787ac25c8.zip
Fix compiler/coverity warnings, add test cases
Diffstat (limited to 'README.md')
-rw-r--r--README.md11
1 files changed, 6 insertions, 5 deletions
diff --git a/README.md b/README.md
index fd7d142..f2e230f 100644
--- a/README.md
+++ b/README.md
@@ -7,10 +7,10 @@
[![Github Releases](https://img.shields.io/github/release/mpaland/printf.svg)](https://github.com/mpaland/printf/releases)
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/mpaland/avl_array/master/LICENSE)
-This is a tiny but fully loaded printf, sprintf and snprintf implementation.
+This is a tiny but **fully loaded** printf, sprintf and snprintf implementation.
Primarily designed for usage in embedded systems, where printf is not available due to memory issues or in avoidance of linking against libc.
Using the standard libc printf may pull **a lot** of unwanted library stuff and can bloat code size about 20k. In this case the following implementation can be used.
-Absolutely **NO dependencies** are required, printf.cpp brings all necessary routines, even its own fast ftoa conversion.
+Absolutely **NO dependencies** are required, printf.cpp brings all necessary routines, even its own fast `ftoa` conversion.
If memory footprint is really a critical issue, floating point support can be turned off via the `PRINTF_FLOAT_SUPPORT` compiler switch.
When using printf (instead of sprintf) you have to provide your own `_putchar()` low level function as console output.
@@ -27,8 +27,8 @@ Therefore I decided to write an own implementation which meets the following ite
- Support of all important flags, width and precision sub-specifiers (see below)
- Support of dec/float number representation (with an own fast itoa/ftoa)
- Reentrant and thread-safe, malloc free
- - LINT and compiler L4 warning free, clean code
- - Extensive test suite passing
+ - LINT and compiler L4 warning free, coverity clean, automotive ready
+ - Extensive test suite (> 260 test cases) passing
- MIT license
@@ -41,7 +41,8 @@ Usage is 1:1 like the according stdio.h library version:
`int sprintf(char* buffer, const char* format, ...);`
`int snprintf(char* buffer, size_t count, const char* format, ...);`
-**Due to genaral security reasons it is highly recommended to use snprintf (with the max buffer size as `count` parameter) only.**
+**Due to genaral security reasons it is highly recommended to use `snprintf` (with the max buffer size as `count` parameter) only.**
+`sprintf` has no buffer limitation, so when necessary - use it with care!
## Format specifiers