]> Git Repo - J-u-boot.git/commitdiff
yaffs2: remove redundant condition
author[email protected] <[email protected]>
Sat, 15 Apr 2017 11:28:13 +0000 (13:28 +0200)
committerTom Rini <[email protected]>
Tue, 18 Apr 2017 14:29:22 +0000 (10:29 -0400)
If !parent, the changed line is not reached.
So there is no need to check the value again.

Signed-off-by: Heinrich Schuchardt <[email protected]>
Reviewed-by: Tom Rini <[email protected]>
fs/yaffs2/yaffsfs.c

index 41e5f0108cf177a6aff51479da2360388bc01892..ba76a5ccdbdb65ab9b5d6a410c81add5f919e7ef 100644 (file)
@@ -3018,7 +3018,7 @@ int yaffs_symlink(const YCHAR *oldpath, const YCHAR *newpath)
                yaffsfs_SetError(-ENFILE);
        else if (parent->my_dev->read_only)
                yaffsfs_SetError(-EROFS);
-       else if (parent) {
+       else {
                obj = yaffs_create_symlink(parent, name, mode, 0, 0, oldpath);
                if (obj)
                        retVal = 0;
This page took 0.037474 seconds and 4 git commands to generate.