summaryrefslogtreecommitdiff
path: root/libcli
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2010-02-01 15:18:15 +0100
committerStefan Metzmacher <metze@samba.org>2010-02-01 15:23:32 +0100
commite37dc56e971f44c00791529a39144d1a972e3ca2 (patch)
tree519af190ca74d4c11ee9567a0fbb970cfb388309 /libcli
parent93142e4a3a0a7dbe5f8ba737bd45f01c61d997da (diff)
downloadsamba-e37dc56e971f44c00791529a39144d1a972e3ca2.tar.gz
samba-e37dc56e971f44c00791529a39144d1a972e3ca2.tar.bz2
samba-e37dc56e971f44c00791529a39144d1a972e3ca2.zip
libcli/nbt: fix ndr_push_nbt_string() string labels with a length of 63 (0x3F) are allowed
metze
Diffstat (limited to 'libcli')
-rw-r--r--libcli/nbt/nbtname.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libcli/nbt/nbtname.c b/libcli/nbt/nbtname.c
index 792b340618..136379a313 100644
--- a/libcli/nbt/nbtname.c
+++ b/libcli/nbt/nbtname.c
@@ -173,9 +173,9 @@ _PUBLIC_ enum ndr_err_code ndr_push_nbt_string(struct ndr_push *ndr, int ndr_fla
complen = strcspn(s, ".");
/* we need to make sure the length fits into 6 bytes */
- if (complen >= 0x3F) {
+ if (complen > 0x3F) {
return ndr_push_error(ndr, NDR_ERR_STRING,
- "component length %u[%08X] > 0x00003F",
+ "component length %u[%08X] > 0x0000003F",
(unsigned)complen, (unsigned)complen);
}