summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-05-06 07:33:28 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:51:46 -0500
commit404c319a5013132edf402e18da0144d7566d2623 (patch)
treec273d21560786a8e4bd7e214adf7586782b85837
parent51803f76c8a05d9ce7b26215bc9ada9216fe6d59 (diff)
downloadsamba-404c319a5013132edf402e18da0144d7566d2623.tar.gz
samba-404c319a5013132edf402e18da0144d7566d2623.tar.bz2
samba-404c319a5013132edf402e18da0144d7566d2623.zip
r511: fix some const handling
(This used to be commit be94cc4032b23fd99823902ddcd1472a72314a88)
-rw-r--r--source4/librpc/ndr/ndr_sec.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source4/librpc/ndr/ndr_sec.c b/source4/librpc/ndr/ndr_sec.c
index 3ea0f4e303..8c1c0c5597 100644
--- a/source4/librpc/ndr/ndr_sec.c
+++ b/source4/librpc/ndr/ndr_sec.c
@@ -53,19 +53,19 @@ NTSTATUS ndr_push_dom_sid2(struct ndr_push *ndr, int ndr_flags, struct dom_sid *
/*
convert a dom_sid to a string
*/
-const char *dom_sid_string(TALLOC_CTX *mem_ctx, const struct dom_sid *sid)
+char *dom_sid_string(TALLOC_CTX *mem_ctx, const struct dom_sid *sid)
{
int i, ofs, maxlen;
uint32 ia;
char *ret;
if (!sid) {
- return "(NULL SID)";
+ return talloc_strdup(mem_ctx, "(NULL SID)");
}
maxlen = sid->num_auths * 11 + 25;
ret = talloc(mem_ctx, maxlen);
- if (!ret) return "(SID ERR)";
+ if (!ret) return talloc_strdup(mem_ctx, "(SID ERR)");
ia = (sid->id_auth[5]) +
(sid->id_auth[4] << 8 ) +