summaryrefslogtreecommitdiff
path: root/source3/nsswitch/winbindd_user.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/nsswitch/winbindd_user.c')
-rw-r--r--source3/nsswitch/winbindd_user.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/nsswitch/winbindd_user.c b/source3/nsswitch/winbindd_user.c
index 9a73b0107b..f3e62d2f7f 100644
--- a/source3/nsswitch/winbindd_user.c
+++ b/source3/nsswitch/winbindd_user.c
@@ -106,7 +106,7 @@ enum winbindd_result winbindd_getpwnam_from_user(struct winbindd_cli_state *stat
return WINBINDD_OK;
}
- slprintf(name,sizeof(name),"%s\\%s", name_domain, name_user);
+ slprintf(name,sizeof(name)-1,"%s\\%s", name_domain, name_user);
/* Get rid and name type from name */
/* the following costs 1 packet */
@@ -364,7 +364,7 @@ enum winbindd_result winbindd_getpwent(struct winbindd_cli_state *state)
/* Prepend domain to name */
- slprintf(domain_user_name, sizeof(domain_user_name),
+ slprintf(domain_user_name, sizeof(domain_user_name)-1,
"%s%s%s", ent->domain->name, lp_winbind_separator(), user_name);
/* Get passwd entry from user name */