diff options
author | Dan Kalowsky <daniel.kalowsky@intel.com> | 2015-10-14 13:34:31 -0700 |
---|---|---|
committer | Anas Nashif <anas.nashif@intel.com> | 2016-02-05 20:24:31 -0500 |
commit | 39063598db77e902523b0ac4b7a1ad6115c73a20 (patch) | |
tree | 61906d718d49883771a0f3bb87b04409247eed4f /lib | |
parent | 3bc403960140409ee96c4c07eeefc800eb3d100e (diff) |
checkpatch: error - spacing
Change-Id: Ie6e1c43581dd4b0734625b3a4e59a4ca79619e99
Signed-off-by: Dan Kalowsky <daniel.kalowsky@intel.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/minimal/source/stdlib/atoi.c | 6 | ||||
-rw-r--r-- | lib/libc/minimal/source/stdout/fprintf.c | 4 |
2 files changed, 6 insertions, 4 deletions
diff --git a/lib/libc/minimal/source/stdlib/atoi.c b/lib/libc/minimal/source/stdlib/atoi.c index 73a3cd9db..50a7dee5c 100644 --- a/lib/libc/minimal/source/stdlib/atoi.c +++ b/lib/libc/minimal/source/stdlib/atoi.c @@ -28,13 +28,15 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. int atoi(const char *s) { - int n=0, neg=0; + int n = 0; + int neg = 0; + while (isspace(*s)) { s++; } switch (*s) { case '-': - neg=1; + neg = 1; case '+': s++; } diff --git a/lib/libc/minimal/source/stdout/fprintf.c b/lib/libc/minimal/source/stdout/fprintf.c index 5f67e22dc..b59640ad6 100644 --- a/lib/libc/minimal/source/stdout/fprintf.c +++ b/lib/libc/minimal/source/stdout/fprintf.c @@ -24,7 +24,7 @@ extern int _prf(int (*func)(), void *dest, const char *format, va_list vargs); -int fprintf(FILE *restrict F, const char *restrict format, ...) +int fprintf(FILE * restrict F, const char *restrict format, ...) { va_list vargs; int r; @@ -36,7 +36,7 @@ int fprintf(FILE *restrict F, const char *restrict format, ...) return r; } -int vfprintf(FILE *restrict F, const char *restrict format, va_list vargs) +int vfprintf(FILE * restrict F, const char *restrict format, va_list vargs) { int r; |