|
Lines 664-670
Link Here
|
| 664 |
goto bad; |
664 |
goto bad; |
| 665 |
} |
665 |
} |
| 666 |
|
666 |
|
| 667 |
printf("* pipe %8x <-> %8x", (int)pi, (int)pip.pipe_peer); |
667 |
printf("* pipe %8lx <-> %8lx", (u_long)pi, (u_long)pip.pipe_peer); |
| 668 |
printf(" %6d", (int)pip.pipe_buffer.cnt); |
668 |
printf(" %6d", (int)pip.pipe_buffer.cnt); |
| 669 |
rw[0] = '\0'; |
669 |
rw[0] = '\0'; |
| 670 |
if (flag & FREAD) |
670 |
if (flag & FREAD) |
|
Lines 762-777
Link Here
|
| 762 |
(void *)so.so_pcb); |
762 |
(void *)so.so_pcb); |
| 763 |
goto bad; |
763 |
goto bad; |
| 764 |
} |
764 |
} |
| 765 |
printf(" %x", (int)inpcb.inp_ppcb); |
765 |
printf(" %lx", (u_long)inpcb.inp_ppcb); |
| 766 |
} |
766 |
} |
| 767 |
} |
767 |
} |
| 768 |
else if (so.so_pcb) |
768 |
else if (so.so_pcb) |
| 769 |
printf(" %x", (int)so.so_pcb); |
769 |
printf(" %lx", (u_long)so.so_pcb); |
| 770 |
break; |
770 |
break; |
| 771 |
case AF_UNIX: |
771 |
case AF_UNIX: |
| 772 |
/* print address of pcb and connected pcb */ |
772 |
/* print address of pcb and connected pcb */ |
| 773 |
if (so.so_pcb) { |
773 |
if (so.so_pcb) { |
| 774 |
printf(" %x", (int)so.so_pcb); |
774 |
printf(" %lx", (u_long)so.so_pcb); |
| 775 |
if (kvm_read(kd, (u_long)so.so_pcb, (char *)&unpcb, |
775 |
if (kvm_read(kd, (u_long)so.so_pcb, (char *)&unpcb, |
| 776 |
sizeof(struct unpcb)) != sizeof(struct unpcb)){ |
776 |
sizeof(struct unpcb)) != sizeof(struct unpcb)){ |
| 777 |
dprintf(stderr, "can't read unpcb at %p\n", |
777 |
dprintf(stderr, "can't read unpcb at %p\n", |
|
Lines 788-801
Link Here
|
| 788 |
if (!(so.so_state & SS_CANTSENDMORE)) |
788 |
if (!(so.so_state & SS_CANTSENDMORE)) |
| 789 |
*cp++ = '>'; |
789 |
*cp++ = '>'; |
| 790 |
*cp = '\0'; |
790 |
*cp = '\0'; |
| 791 |
printf(" %s %x", shoconn, |
791 |
printf(" %s %lx", shoconn, |
| 792 |
(int)unpcb.unp_conn); |
792 |
(u_long)unpcb.unp_conn); |
| 793 |
} |
793 |
} |
| 794 |
} |
794 |
} |
| 795 |
break; |
795 |
break; |
| 796 |
default: |
796 |
default: |
| 797 |
/* print protocol number and socket address */ |
797 |
/* print protocol number and socket address */ |
| 798 |
printf(" %d %x", proto.pr_protocol, (int)sock); |
798 |
printf(" %d %lx", proto.pr_protocol, (u_long)sock); |
| 799 |
} |
799 |
} |
| 800 |
printf("\n"); |
800 |
printf("\n"); |
| 801 |
return; |
801 |
return; |