summaryrefslogtreecommitdiff
path: root/source3/nsswitch/winbindd_idmap.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-04-08 20:22:39 +0000
committerJeremy Allison <jra@samba.org>2001-04-08 20:22:39 +0000
commitf9a15ce1a69f905e94db7650f0a4805720cd9c88 (patch)
treeee37b735477fe7eaea7cb16a30d126971aae8d5b /source3/nsswitch/winbindd_idmap.c
parent607d5d508d091d6c9b9cd6549b2a89f7359d780c (diff)
downloadsamba-f9a15ce1a69f905e94db7650f0a4805720cd9c88.tar.gz
samba-f9a15ce1a69f905e94db7650f0a4805720cd9c88.tar.bz2
samba-f9a15ce1a69f905e94db7650f0a4805720cd9c88.zip
Got "medieval on our ass" about adding the -1 to slprintf.
Jeremy. (This used to be commit 94747b4639ed9b19f7d0fb896e43aa392a84989a)
Diffstat (limited to 'source3/nsswitch/winbindd_idmap.c')
-rw-r--r--source3/nsswitch/winbindd_idmap.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/nsswitch/winbindd_idmap.c b/source3/nsswitch/winbindd_idmap.c
index ff0818c456..11f7b8aae7 100644
--- a/source3/nsswitch/winbindd_idmap.c
+++ b/source3/nsswitch/winbindd_idmap.c
@@ -77,7 +77,7 @@ static BOOL get_id_from_rid(char *domain_name, uint32 rid, int *id,
/* Check if rid is present in database */
- slprintf(keystr, sizeof(keystr), "%s/%d", domain_name, rid);
+ slprintf(keystr, sizeof(keystr)-1, "%s/%d", domain_name, rid);
dos_to_unix(keystr, True); /* Convert key to unix-codepage */
key.dptr = keystr;
@@ -116,7 +116,7 @@ static BOOL get_id_from_rid(char *domain_name, uint32 rid, int *id,
/* Store new id */
- slprintf(keystr2, sizeof(keystr2), "%s %d", isgroup ? "GID" :
+ slprintf(keystr2, sizeof(keystr2)-1, "%s %d", isgroup ? "GID" :
"UID", *id);
data.dptr = keystr2;
@@ -155,7 +155,7 @@ BOOL get_rid_from_id(int id, uint32 *rid, struct winbindd_domain **domain,
fstring keystr;
BOOL result = False;
- slprintf(keystr, sizeof(keystr), "%s %d", isgroup ? "GID" : "UID", id);
+ slprintf(keystr, sizeof(keystr)-1, "%s %d", isgroup ? "GID" : "UID", id);
key.dptr = keystr;
key.dsize = strlen(keystr) + 1;