kernel/fs: Fix some minor coding style issues.
This commit is contained in:
@@ -188,8 +188,8 @@ put_fd(struct file_descriptor* descriptor)
|
||||
|
||||
object_cache_free(sFileDescriptorCache, descriptor, 0);
|
||||
} else if ((descriptor->open_mode & O_DISCONNECTED) != 0
|
||||
&& previous - 1 == descriptor->open_count
|
||||
&& descriptor->ops != NULL) {
|
||||
&& previous - 1 == descriptor->open_count
|
||||
&& descriptor->ops != NULL) {
|
||||
// the descriptor has been disconnected - it cannot
|
||||
// be accessed anymore, let's close it (no one is
|
||||
// currently accessing this descriptor)
|
||||
|
||||
@@ -6029,13 +6029,13 @@ dir_open_entry_ref(dev_t mountID, ino_t parentID, const char* name, bool kernel)
|
||||
{
|
||||
FUNCTION(("dir_open_entry_ref()\n"));
|
||||
|
||||
if (name && name[0] == '\0')
|
||||
if (name != NULL && name[0] == '\0')
|
||||
return B_BAD_VALUE;
|
||||
|
||||
// get the vnode matching the entry_ref/node_ref
|
||||
VnodePutter vnode;
|
||||
status_t status;
|
||||
if (name) {
|
||||
if (name != NULL) {
|
||||
status = entry_ref_to_vnode(mountID, parentID, name, true, kernel,
|
||||
vnode);
|
||||
} else {
|
||||
@@ -7482,7 +7482,7 @@ fs_mount(char* path, const char* device, const char* fsName, uint32 flags,
|
||||
KPath normalizedDevice;
|
||||
bool newlyCreatedFileDevice = false;
|
||||
|
||||
if (!(flags & B_MOUNT_VIRTUAL_DEVICE) && device != NULL) {
|
||||
if ((flags & B_MOUNT_VIRTUAL_DEVICE) == 0 && device != NULL) {
|
||||
// normalize the device path
|
||||
status = normalizedDevice.SetTo(device, true);
|
||||
if (status != B_OK)
|
||||
|
||||
Reference in New Issue
Block a user