More references to avsprintf that need to be changed vasprintf
This commit is contained in:
parent
5306a27335
commit
6b1d61c759
@ -1,7 +1,7 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* apps/n etutils/ftpd.c
|
* apps/n etutils/ftpd.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
|
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
*
|
*
|
||||||
* Includes original code as well as logic adapted from hwport_ftpd, written
|
* Includes original code as well as logic adapted from hwport_ftpd, written
|
||||||
@ -977,7 +977,7 @@ static ssize_t ftpd_response(int sd, int timeout, FAR const char *fmt, ...)
|
|||||||
va_list ap;
|
va_list ap;
|
||||||
|
|
||||||
va_start(ap, fmt);
|
va_start(ap, fmt);
|
||||||
avsprintf(&buffer, fmt, ap);
|
vasprintf(&buffer, fmt, ap);
|
||||||
va_end(ap);
|
va_end(ap);
|
||||||
|
|
||||||
if (!buffer)
|
if (!buffer)
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* apps/nshlib/nsh_console.c
|
* apps/nshlib/nsh_console.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2007-2009, 2011-2013 Gregory Nutt. All rights reserved.
|
* Copyright (C) 2007-2009, 2011-2013, 2015 Gregory Nutt. All rights reserved.
|
||||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
@ -240,13 +240,13 @@ static int nsh_consoleoutput(FAR struct nsh_vtbl_s *vtbl,
|
|||||||
va_list ap;
|
va_list ap;
|
||||||
char *str;
|
char *str;
|
||||||
|
|
||||||
/* Use avsprintf() to allocate a buffer and fill it with the formatted
|
/* Use vasprintf() to allocate a buffer and fill it with the formatted
|
||||||
* data
|
* data
|
||||||
*/
|
*/
|
||||||
|
|
||||||
va_start(ap, fmt);
|
va_start(ap, fmt);
|
||||||
str = NULL;
|
str = NULL;
|
||||||
(void)avsprintf(&str, fmt, ap);
|
(void)vasprintf(&str, fmt, ap);
|
||||||
|
|
||||||
/* Was a string allocated? */
|
/* Was a string allocated? */
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user