summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2007-12-15 22:08:09 +0100
committerVolker Lendecke <vl@samba.org>2007-12-15 22:09:37 +0100
commit4312ad8b98456a59bd5b020d83010695b4baf209 (patch)
treeca8ae6650953b7ca9438edd2104dc801fb3b1e91
parent14ef4cdec1ab6be55c97d0f32780cbddbcdde218 (diff)
downloadsamba-4312ad8b98456a59bd5b020d83010695b4baf209.tar.gz
samba-4312ad8b98456a59bd5b020d83010695b4baf209.tar.bz2
samba-4312ad8b98456a59bd5b020d83010695b4baf209.zip
sid_string_static is no more :-)
We now have four ways to do sid_to_string: sid_to_string: Convert it into an existing fstring, when you have one sid_string_talloc: The obvious thing sid_string_tos: For the lazy, use only with care sid_string_dbg: The one to use in DEBUG statements (This used to be commit 7b8276aaa48852270c6b70b081c3f28e316a7a2c)
-rw-r--r--source3/lib/util_sid.c19
1 files changed, 8 insertions, 11 deletions
diff --git a/source3/lib/util_sid.c b/source3/lib/util_sid.c
index e27c72dbc4..b28626cd66 100644
--- a/source3/lib/util_sid.c
+++ b/source3/lib/util_sid.c
@@ -202,17 +202,6 @@ char *sid_to_string(fstring sidstr_out, const DOM_SID *sid)
return sidstr_out;
}
-/*****************************************************************
- Useful function for debug lines.
-*****************************************************************/
-
-const char *sid_string_static(const DOM_SID *sid)
-{
- static fstring sid_str;
- sid_to_string(sid_str, sid);
- return sid_str;
-}
-
char *sid_string_talloc(TALLOC_CTX *mem_ctx, const DOM_SID *sid)
{
fstring sid_str;
@@ -223,11 +212,19 @@ char *sid_string_talloc(TALLOC_CTX *mem_ctx, const DOM_SID *sid)
return result;
}
+/*****************************************************************
+ Useful function for debug lines.
+*****************************************************************/
+
char *sid_string_dbg(const DOM_SID *sid)
{
return sid_string_talloc(debug_ctx(), sid);
}
+/*****************************************************************
+ Use with care!
+*****************************************************************/
+
char *sid_string_tos(const DOM_SID *sid)
{
return sid_string_talloc(talloc_tos(), sid);