You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/05/09 05:50:30 UTC

[GitHub] [incubator-nuttx] xiaoxiang781216 commented on a change in pull request #3682: fs: nx_dup2 should return zero(OK) in the sucess

xiaoxiang781216 commented on a change in pull request #3682:
URL: https://github.com/apache/incubator-nuttx/pull/3682#discussion_r628838160



##########
File path: fs/inode/fs_files.c
##########
@@ -432,7 +432,7 @@ int nx_dup2(int fd1, int fd2)
                                  [fd2 % CONFIG_NFILE_DESCRIPTORS_PER_BLOCK]);
   _files_semgive(list);
 
-  return ret < 0 ? ret : fd2;
+  return ret;

Review comment:
       Yes, you are right.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org