Memory leak in error case. CID 873.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25642 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
06a28b5416
commit
7ad3cf0bc3
|
@ -2965,8 +2965,10 @@ devfs_publish_file_device(const char *path, const char *filePath)
|
|||
RecursiveLocker locker(&sDeviceFileSystem->lock);
|
||||
|
||||
status = new_node(sDeviceFileSystem, path, &node, &dirNode);
|
||||
if (status != B_OK)
|
||||
if (status != B_OK) {
|
||||
free((char*)filePath);
|
||||
return status;
|
||||
}
|
||||
|
||||
// all went fine, let's initialize the node
|
||||
node->stream.type = S_IFLNK | 0644;
|
||||
|
|
Loading…
Reference in New Issue