git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e4df1ed
)
Fix bug #7528 - Solaris with NIS autohome.
author
Jeremy Allison
<jra@samba.org>
Wed, 1 Jun 2011 18:38:48 +0000
(20:38 +0200)
committer
Karolin Seeger
<kseeger@samba.org>
Tue, 14 Jun 2011 10:58:50 +0000
(12:58 +0200)
(cherry picked from commit
0ffdf2288b1e6798e43259568818378c43b979e5
)
source3/lib/util.c
patch
|
blob
|
history
diff --git
a/source3/lib/util.c
b/source3/lib/util.c
index 46be349a2c22d0253642eaecc72ea96e35f078af..238981debc1263cf3a607966f080495dd9748214 100644
(file)
--- a/
source3/lib/util.c
+++ b/
source3/lib/util.c
@@
-1312,6
+1312,9
@@
char *automount_lookup(TALLOC_CTX *ctx, const char *user_name)
if ((nis_error = yp_match(nis_domain, nis_map, user_name,
strlen(user_name), &nis_result,
&nis_result_len)) == 0) {
+ if (nis_result_len > 0 && nis_result[nis_result_len] == '\n') {
+ nis_result[nis_result_len] = '\0';
+ }
value = talloc_strdup(ctx, nis_result);
if (!value) {
return NULL;