summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalph Boehme <slow@samba.org>2019-02-22 16:29:07 +0100
committerKarolin Seeger <kseeger@samba.org>2019-03-05 07:39:28 +0000
commit8234ef264a7d9344b412a0b2b36dc4c6b47876e4 (patch)
tree713d89410020462b6b963a2c250d976ec8deff51
parenta76277af385b10518dccf83ccb1b49173d625881 (diff)
downloadsamba-8234ef264a7d9344b412a0b2b36dc4c6b47876e4.tar.gz
winbindd: make xids a const argument to wb_xids2sids_send()
The previous commit made an internal copy of xids, this commit makes it more obvious that we must not mess with the xids argument but treat it as an in-parameter and don't write to it. Bug: https://bugzilla.samba.org/show_bug.cgi?id=13802 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> (cherry picked from commit 5d277ea7ea258676b9ea5081a451a5874af115f6)
-rw-r--r--source3/winbindd/wb_xids2sids.c2
-rw-r--r--source3/winbindd/winbindd_proto.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/source3/winbindd/wb_xids2sids.c b/source3/winbindd/wb_xids2sids.c
index f4ff1a577d0..aba83823c7b 100644
--- a/source3/winbindd/wb_xids2sids.c
+++ b/source3/winbindd/wb_xids2sids.c
@@ -437,7 +437,7 @@ static void wb_xids2sids_init_dom_maps_done(struct tevent_req *subreq);
struct tevent_req *wb_xids2sids_send(TALLOC_CTX *mem_ctx,
struct tevent_context *ev,
- struct unixid *xids,
+ const struct unixid *xids,
uint32_t num_xids)
{
struct tevent_req *req, *subreq;
diff --git a/source3/winbindd/winbindd_proto.h b/source3/winbindd/winbindd_proto.h
index 85cd50b8ed7..3a94a201c27 100644
--- a/source3/winbindd/winbindd_proto.h
+++ b/source3/winbindd/winbindd_proto.h
@@ -925,7 +925,7 @@ NTSTATUS winbindd_sids_to_xids_recv(struct tevent_req *req,
struct winbindd_response *response);
struct tevent_req *wb_xids2sids_send(TALLOC_CTX *mem_ctx,
struct tevent_context *ev,
- struct unixid *xids,
+ const struct unixid *xids,
uint32_t num_xids);
NTSTATUS wb_xids2sids_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
struct dom_sid **sids);