summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRasmus Villemoes <linux@rasmusvillemoes.dk>2014-11-27 22:25:45 +0100
committerLuis Henriques <luis.henriques@canonical.com>2015-02-04 10:58:29 +0000
commita2d1d5aad710be8f4bb39552756dbf72957096bf (patch)
treeed8a9be85e3cd0f478ed2aef149aede7f5e97fb3 /include
parent4960ce27c359a48ecaa553c2ac07feca1c4a4af0 (diff)
usb: musb: Fix a few off-by-one lengths
commit e87c3f80ad0490d26ffe04754b7d094463b40f30 upstream. !strncmp(buf, "force host", 9) is true if and only if buf starts with "force hos". This was obviously not what was intended. The same error exists for "force full-speed", "force high-speed" and "test packet". Using strstarts avoids the error-prone hardcoding of the prefix length. For consistency, also change the other occurences of the !strncmp idiom. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions