libc: Add IPTR for puts/fputs

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I2a83afb4d934a44ad1b56ec6dd72e654f4e112a3
This commit is contained in:
Xiang Xiao
2020-06-10 00:03:53 -07:00
committed by Brennan Ashton
parent 4fbbd2e3bf
commit 43d7c1e807
4 changed files with 10 additions and 10 deletions
+5 -5
View File
@@ -1,7 +1,8 @@
/****************************************************************************
* libs/libc/stdio/lib_fputs.c
*
* Copyright (C) 2007, 2008, 2011-2012, 2017 Gregory Nutt. All rights reserved.
* Copyright (C) 2007, 2008, 2011-2012, 2017 Gregory Nutt.
* All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
@@ -60,7 +61,7 @@
****************************************************************************/
#if defined(CONFIG_ARCH_ROMGETC)
int fputs(FAR const char *s, FAR FILE *stream)
int fputs(FAR const IPTR char *s, FAR FILE *stream)
{
int nput;
int ret;
@@ -104,7 +105,7 @@ int fputs(FAR const char *s, FAR FILE *stream)
}
#else
int fputs(FAR const char *s, FAR FILE *stream)
int fputs(FAR const IPTR char *s, FAR FILE *stream)
{
int nput;
@@ -151,7 +152,7 @@ int fputs(FAR const char *s, FAR FILE *stream)
}
}
/* Without line buffering, we can write the whole string in one operation. */
/* We can write the whole string in one operation without line buffering */
else
{
@@ -172,7 +173,6 @@ int fputs(FAR const char *s, FAR FILE *stream)
{
return EOF;
}
}
return nput;
+1 -1
View File
@@ -52,7 +52,7 @@
*
****************************************************************************/
int puts(FAR const char *s)
int puts(FAR const IPTR char *s)
{
FILE *stream = stdout;
int nwritten;