From 814d5a5011038164dd55dd9e593989f69cedef0d Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sun, 19 Jun 2005 01:17:29 +0000 Subject: r7739: fixed an off by one bug in the base64 decoder for ldb ldif (This used to be commit fe2b77af2352f1964402a4286105916e990dc36f) --- source4/lib/ldb/common/ldb_ldif.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source4/lib/ldb/common/ldb_ldif.c b/source4/lib/ldb/common/ldb_ldif.c index 546cf461f8..225fa3f3c9 100644 --- a/source4/lib/ldb/common/ldb_ldif.c +++ b/source4/lib/ldb/common/ldb_ldif.c @@ -71,6 +71,9 @@ static int base64_decode(char *s) } s++; i++; } + if (bit_offset >= 3) { + n--; + } if (*s && !p) { /* the only termination allowed */ -- cgit