Reference count field was not being initialized
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@90 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
50dcba1464
commit
05dcf3642b
|
@ -90,11 +90,9 @@ static FAR struct inode *inode_alloc(const char *name,
|
|||
mode_t mode, void *private)
|
||||
{
|
||||
int namelen = inode_namelen(name);
|
||||
FAR struct inode *node = (FAR struct inode*)malloc(FSNODE_SIZE(namelen));
|
||||
FAR struct inode *node = (FAR struct inode*)zalloc(FSNODE_SIZE(namelen));
|
||||
if (node)
|
||||
{
|
||||
node->i_peer = NULL;
|
||||
node->i_child = NULL;
|
||||
node->i_ops = fops;
|
||||
#ifdef CONFIG_FILE_MODE
|
||||
node->i_mode = mode;
|
||||
|
|
Loading…
Reference in New Issue