mirror of
https://github.com/apache/nuttx.git
synced 2026-05-28 20:08:15 +08:00
Partial testing of wget command
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1660 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -319,7 +319,7 @@ static const struct cmdmap_s g_cmdmap[] =
|
|||||||
|
|
||||||
#if defined(CONFIG_NET_TCP) && CONFIG_NFILE_DESCRIPTORS > 0
|
#if defined(CONFIG_NET_TCP) && CONFIG_NFILE_DESCRIPTORS > 0
|
||||||
# ifndef CONFIG_EXAMPLES_NSH_DISABLE_GET
|
# ifndef CONFIG_EXAMPLES_NSH_DISABLE_GET
|
||||||
{ "wget", cmd_wget, 2, 3, "[-o <local-path>] <url>" },
|
{ "wget", cmd_wget, 2, 4, "[-o <local-path>] <url>" },
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -740,7 +740,7 @@ int cmd_wget(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv)
|
|||||||
|
|
||||||
/* And perform the wget */
|
/* And perform the wget */
|
||||||
|
|
||||||
ret = wget(argv[1], buffer, 512, wget_callback, (FAR void *)fd);
|
ret = wget(url, buffer, 512, wget_callback, (FAR void *)fd);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
{
|
{
|
||||||
nsh_output(vtbl, g_fmtcmdfailed, argv[0], "wget", NSH_ERRNO);
|
nsh_output(vtbl, g_fmtcmdfailed, argv[0], "wget", NSH_ERRNO);
|
||||||
|
|||||||
Reference in New Issue
Block a user