patacongo commented on a change in pull request #4121:
URL: https://github.com/apache/incubator-nuttx/pull/4121#discussion_r668835377



##########
File path: fs/vfs/fs_stat.c
##########
@@ -120,6 +120,10 @@ static int stat_recursive(FAR const char *path,
 
           ret = inode->u.i_mops->stat(inode, desc.relpath, buf);
         }
+      else
+        {
+          ret = -ENOSYS;

Review comment:
       > But one thing that was bugging me was that `-ENOSYS` is intended for 
**optional** features that are not implemented, which is not the the case for 
`stat`.
   
   Then perhaps you might consider -ENOTSUP.  “Not supported.  A function 
returns this error when certain parameter values are valid, but the 
functionality they request is not available. This can mean that the function 
does not implement a particular command or option value or flag bit at all. ..."
   
   BUT:  "If the entire function is not available at all in the implementation, 
 it returns ENOSYS instead."
   




-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to