summaryrefslogtreecommitdiff
path: root/source3/libsmb
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2010-02-09 12:17:08 -0800
committerJeremy Allison <jra@samba.org>2010-02-09 12:17:08 -0800
commit9ad6f432f3f5844b4b419e7cbaf3c3e70b052d29 (patch)
tree84e199ee03443bbebf2ae1867e8c62e08f38bf87 /source3/libsmb
parentbc8242a08e1bb9489cc8171b1ec02bd2518b1857 (diff)
downloadsamba-9ad6f432f3f5844b4b419e7cbaf3c3e70b052d29.tar.gz
samba-9ad6f432f3f5844b4b419e7cbaf3c3e70b052d29.tar.bz2
samba-9ad6f432f3f5844b4b419e7cbaf3c3e70b052d29.zip
Fix off-by-one error in working out the limit of the NetServerEnum comment.
Jeremy.
Diffstat (limited to 'source3/libsmb')
-rw-r--r--source3/libsmb/clirap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/libsmb/clirap.c b/source3/libsmb/clirap.c
index 7f6dbf5bbb..990b8063ca 100644
--- a/source3/libsmb/clirap.c
+++ b/source3/libsmb/clirap.c
@@ -367,7 +367,7 @@ bool cli_NetServerEnum(struct cli_state *cli, char *workgroup, uint32 stype,
comment_offset = (IVAL(p,22) & 0xFFFF)-converter;
cmnt = comment_offset?(rdata+comment_offset):"";
- if (comment_offset < 0 || comment_offset > (int)rdrcnt) {
+ if (comment_offset < 0 || comment_offset >= (int)rdrcnt) {
TALLOC_FREE(frame);
continue;
}