git.samba.org
/
ira
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8a27fde
)
s3:net simplify padding to single printf call
author
Björn Jacke
<bj@sernet.de>
Tue, 13 Oct 2009 22:19:35 +0000
(
00:19
+0200)
committer
Björn Jacke
<bj@sernet.de>
Tue, 13 Oct 2009 22:19:35 +0000
(
00:19
+0200)
source3/utils/net_rpc.c
patch
|
blob
|
history
diff --git
a/source3/utils/net_rpc.c
b/source3/utils/net_rpc.c
index 0e325b52697cea7a55eb79797726fab959b5b77e..455405a3ee899a37a691bbb3cb5227e349f31959 100644
(file)
--- a/
source3/utils/net_rpc.c
+++ b/
source3/utils/net_rpc.c
@@
-5777,18
+5777,12
@@
static NTSTATUS rpc_query_domain_sid(struct net_context *c,
static void print_trusted_domain(DOM_SID *dom_sid, const char *trusted_dom_name)
{
static void print_trusted_domain(DOM_SID *dom_sid, const char *trusted_dom_name)
{
- fstring ascii_sid, padding;
- int pad_len, col_len = 20;
+ fstring ascii_sid;
/* convert sid into ascii string */
sid_to_fstring(ascii_sid, dom_sid);
/* convert sid into ascii string */
sid_to_fstring(ascii_sid, dom_sid);
- /* calculate padding space for d_printf to look nicer */
- pad_len = col_len - strlen(trusted_dom_name);
- padding[pad_len] = 0;
- do padding[--pad_len] = ' '; while (pad_len);
-
- d_printf("%s%s%s\n", trusted_dom_name, padding, ascii_sid);
+ d_printf("%-20s%s\n", trusted_dom_name, ascii_sid);
}
static NTSTATUS vampire_trusted_domain(struct rpc_pipe_client *pipe_hnd,
}
static NTSTATUS vampire_trusted_domain(struct rpc_pipe_client *pipe_hnd,