summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2007-07-22 18:01:20 +0200
committerAdrian Bunk <bunk@stusta.de>2007-07-22 18:01:20 +0200
commit4e4c0eaae96b9a10dbde07acde81a1b488e1062e (patch)
tree60329983941ea9c3f9d0530995e86e53208fedaa /drivers
parent1b80f9a0d13e0210ef56c3d2d0afc33e60e547a8 (diff)
ieee1394: forgotten dereference...
Going through the string and waiting for _pointer_ to become '\0' is not what the authors meant... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Acked-by: Ben Collins <ben.collins@ubuntu.com> Signed-off-by: Adrian Bunk <bunk@stusta.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/ieee1394/nodemgr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ieee1394/nodemgr.c b/drivers/ieee1394/nodemgr.c
index 082c7fd239f5..8805a27b63e6 100644
--- a/drivers/ieee1394/nodemgr.c
+++ b/drivers/ieee1394/nodemgr.c
@@ -240,7 +240,7 @@ static ssize_t fw_show_##class##_##td_kv (struct device *dev, struct device_attr
memcpy(buf, \
CSR1212_TEXTUAL_DESCRIPTOR_LEAF_DATA(class->td_kv), \
len); \
- while ((buf + len - 1) == '\0') \
+ while (buf[len - 1] == '\0') \
len--; \
buf[len++] = '\n'; \
buf[len] = '\0'; \