utils/stat.c
/*
 * create_vfs_node - create a new entry in the virtual file system with the
 *                   specified path
 *
 * @path_without_name - the path without the filename
 * @path              - the complete path with the filenamee
 * @path_len          - the length of the full path
 **
 */
create a new entry in the virtual file system with the
specified path

@path_without_name - the path without the filename
@path              - the complete path with the filenamee
@path_len          - the length of the full path
create a new entry in the virtual file system with the specified path @path_without_name - the path without the filename @path - the complete path with the filenamee @path_len - the length of the full path
static struct vfs_node_s *create_vfs_node(const char *path_without_name,
                                          const char *path,
                                          size_t path_len)
{
  struct vfs_node_s *node;
  struct vfs_ops_s *ops;
  int ret;
  ops = vfs_get_supported_operations(path_without_name);
  ret = vfs_register_node(path,
                          path_len,
                          ops,
                          VFS_TYPE_FILE,
                          NULL);
  if (ret != OK) {
    return NULL;
  }
  node = vfs_get_matching_node(path, path_len);
  return node;
}
static struct vfs_node_s * create_vfs_node ( const char * path_without_name , const char * path , size_t path_len ) { struct vfs_node_s * node ; struct vfs_ops_s * ops ; int ret ; ops = vfs_get_supported_operations ( path_without_name ) ; ret = vfs_register_node ( path , path_len , ops , VFS_TYPE_FILE , NULL ) ; if ( ret != OK ) { return NULL ; } node = vfs_get_matching_node ( path , path_len ) ; return node ; }
create_vfs_node - create a new entry in the virtual file system with the
                   specified path
create_vfs_node - create a new entry in the virtual file system with the specified path