diff options
Diffstat (limited to 'nuttx/net/net_vfcntl.c')
-rw-r--r-- | nuttx/net/net_vfcntl.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/nuttx/net/net_vfcntl.c b/nuttx/net/net_vfcntl.c index bf3e37d81..537a9031d 100644 --- a/nuttx/net/net_vfcntl.c +++ b/nuttx/net/net_vfcntl.c @@ -50,6 +50,10 @@ #if defined(CONFIG_NET) && CONFIG_NSOCKET_DESCRIPTORS > 0 /**************************************************************************** + * Pre-Processor Definitions + ****************************************************************************/ + +/**************************************************************************** * Global Functions ****************************************************************************/ @@ -67,7 +71,7 @@ int net_vfcntl(int sockfd, int cmd, va_list ap) goto errout; } -#warning "fcntl() commands not yet implemented" +#warning "Most fcntl() commands not yet implemented" switch (cmd) { case F_DUPFD: @@ -81,6 +85,11 @@ int net_vfcntl(int sockfd, int cmd, va_list ap) * exec functions. */ + { + ret = net_dup(sockfd, va_arg(ap, int)); + } + break; + case F_GETFD: /* Get the file descriptor flags defined in <fcntl.h> that are associated * with the file descriptor fildes. File descriptor flags are associated |