net_usershare: Use dom_sid_str_buf
authorVolker Lendecke <vl@samba.org>
Thu, 6 Dec 2018 17:20:06 +0000 (18:20 +0100)
committerJeremy Allison <jra@samba.org>
Fri, 7 Dec 2018 22:29:00 +0000 (23:29 +0100)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/utils/net_usershare.c

index 8357296f72793734f05a0f0ba421fe8638a974e1..1e2925979d0ea396939b8ca7478f528f1f8b8bf2 100644 (file)
@@ -446,12 +446,14 @@ static int info_fn(struct file_list *fl, void *priv)
                        }
 
                } else {
-                       fstring sidstr;
-                       sid_to_fstring(sidstr,
-                                      &psd->dacl->aces[num_aces].trustee);
-                       acl_str = talloc_asprintf_append(acl_str,
-                                               "%s",
-                                               sidstr);
+                       struct dom_sid_buf sidstr;
+
+                       acl_str = talloc_asprintf_append(
+                               acl_str,
+                               "%s",
+                               dom_sid_str_buf(
+                                       &psd->dacl->aces[num_aces].trustee,
+                                       &sidstr));
                        if (!acl_str) {
                                return -1;
                        }