Ticket #6318: src_bin_listport.patch

File src_bin_listport.patch, 1.6 KB (added by Karvjorm, 9 years ago)

an output fix for src/bin/listport.c

  • src/bin/listport.c

     
    11// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
    22//
    33//  Copyright (c) 2001-2003, OpenBeOS
     4//  Copyright (c) 2010, Haiku Inc.
    45//
    56//  This software is part of the OpenBeOS distribution and is covered
    67//  by the OpenBeOS license.
    78//
    89//
    910//  File:        listport.c
    10 //  Author:      Daniel Reinhold (danielre@users.sf.net)
     11//  Author:      Daniel Reinhold (danielre@users.sf.net), output fix by
     12//               Jorma Karvonen (karvonen.jorma @ gmail.com)
    1113//  Description: lists all open ports in the system, organized by team
    1214//
    1315// ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
     
    2123void show_port_totals (void);
    2224
    2325
    24 
    2526int
    2627main(int argc, char **argv)
    2728{
     
    7374        return;
    7475    }
    7576
    76     printf("\nTEAM %4ld (%s):\n", id, this_team.args);
    77     printf("   ID                         name  capacity  queued\n");
    78     printf("----------------------------------------------------\n");
     77    printf("\nTEAM %5ld (%s):\n", id, this_team.args);
     78    printf("        ID                           name  capacity  queued\n");
     79    printf("-----------------------------------------------------------\n");
    7980   
    8081    while (get_next_port_info(id, &cookie, &this_port) == B_OK) {
    81         printf("%5ld %28s  %8ld  %6ld\n",
     82        printf("%10ld %30s  %8ld  %6ld\n",
    8283                this_port.port,
    8384                this_port.name,
    8485                this_port.capacity,