This is an automated email from the ASF dual-hosted git repository. xiaoxiang pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-nuttx-apps.git
commit 78e8090842bbd3123a58629e94d30144954f6ef4 Author: SPRESENSE <41312067+sprese...@users.noreply.github.com> AuthorDate: Fri Aug 7 14:13:56 2020 +0900 examples: wget: Fix nxstyle issues --- examples/wget/wget_main.c | 6 ++++-- netutils/webclient/webclient.c | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/examples/wget/wget_main.c b/examples/wget/wget_main.c index 1f3897b..3b634d9 100644 --- a/examples/wget/wget_main.c +++ b/examples/wget/wget_main.c @@ -53,7 +53,8 @@ * Preprocessor Definitions ****************************************************************************/ -/* Configuration Checks ******************************************************/ +/* Configuration Checks *****************************************************/ + /* BEWARE: * There are other configuration settings needed in netutitls/wget/wgetc.s, * but there are default values for those so we cannot check them here. @@ -88,6 +89,7 @@ static char g_iobuffer[512]; /**************************************************************************** * Private Functions ****************************************************************************/ + /**************************************************************************** * Name: callback ****************************************************************************/ @@ -114,7 +116,7 @@ int main(int argc, FAR char *argv[]) uint8_t mac[IFHWADDRLEN]; #endif -/* Many embedded network interfaces must have a software assigned MAC */ + /* Many embedded network interfaces must have a software assigned MAC */ #ifdef CONFIG_EXAMPLES_WGET_NOMAC mac[0] = 0x00; diff --git a/netutils/webclient/webclient.c b/netutils/webclient/webclient.c index 8773f11..0a70d0e 100644 --- a/netutils/webclient/webclient.c +++ b/netutils/webclient/webclient.c @@ -666,9 +666,10 @@ static int wget_base(FAR const char *url, FAR char *buffer, int buflen, nerr("ERROR: send failed: %d\n", errno); goto errout; } + len -= ret; } - while(len > 0); + while (len > 0); /* Now loop to get the file sent in response to the GET. This * loop continues until either we read the end of file (nbytes == 0)