r13083: patch suggested by Adam Nielsen for better smbstatus formatting
authorGerald Carter <jerry@samba.org>
Mon, 23 Jan 2006 14:26:48 +0000 (14:26 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 16:06:13 +0000 (11:06 -0500)
(This used to be commit ef69cf96145516ddca44fdb4faddfead26591345)

source3/utils/status.c

index f19a217aa6581090dfaadb06571342ac6bd07cdd..b9f1c161e48ec5558c62d80a5ec1f271548b9657 100644 (file)
@@ -103,13 +103,13 @@ static void print_share_mode(const struct share_mode_entry *e, const char *share
        static int count;
        if (count==0) {
                d_printf("Locked files:\n");
-               d_printf("Pid    DenyMode   Access      R/W        Oplock           SharePath           Name\n");
-               d_printf("----------------------------------------------------------------------------------\n");
+               d_printf("Pid          DenyMode   Access      R/W        Oplock           SharePath           Name\n");
+               d_printf("----------------------------------------------------------------------------------------\n");
        }
        count++;
 
        if (Ucrit_checkPid(procid_to_pid(&e->pid))) {
-               d_printf("%s  ",procid_str_static(&e->pid));
+               d_printf("%-11s  ",procid_str_static(&e->pid));
                switch (map_share_mode_to_deny_mode(e->share_access,
                                                    e->private_options)) {
                        case DENY_NONE: d_printf("DENY_NONE  "); break;
@@ -166,7 +166,7 @@ static void print_brl(SMB_DEV_T dev, SMB_INO_T ino, struct process_id pid,
        }
        count++;
 
-       d_printf("%s   %05x:%05x    %s  %9.0f   %9.0f\n", 
+       d_printf("%08s   %05x:%05x    %s  %9.0f   %9.0f\n", 
               procid_str_static(&pid), (int)dev, (int)ino, 
               lock_type==READ_LOCK?"R":"W",
               (double)start, (double)size);