]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commitdiff
stm class: Remove unnecessary pointer increment
authorAlexander Shishkin <alexander.shishkin@linux.intel.com>
Fri, 4 Mar 2016 14:55:12 +0000 (16:55 +0200)
committerAlexander Shishkin <alexander.shishkin@linux.intel.com>
Fri, 8 Apr 2016 13:11:54 +0000 (16:11 +0300)
Readability: a postfix increment is used on a pointer which is not
used anywhere afterwards, which may send the reader looking through
the function one extra time. Drop the unnecessary increment.

Reported-by: Alan Cox <alan.cox@intel.com>
Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Reviewed-by: Laurent Fert <laurent.fert@intel.com>
drivers/hwtracing/stm/policy.c

index e8b50b1ac61942903346beb182676ec8e4d900ac..6c0ae29963267b4cdbea055c994c488f0faddd5f 100644 (file)
@@ -341,7 +341,7 @@ stp_policies_make(struct config_group *group, const char *name)
                return ERR_PTR(-EINVAL);
        }
 
-       *p++ = '\0';
+       *p = '\0';
 
        stm = stm_find_device(devname);
        kfree(devname);