1char *copyright = 2 "Copyright (c) 1984 through 1996, William LeFebvre"; 3 4/* 5 * Top users/processes display for Unix 6 * Version 3 7 * 8 * This program may be freely redistributed, 9 * but this entire comment MUST remain intact. 10 * 11 * Copyright (c) 1984, 1989, William LeFebvre, Rice University 12 * Copyright (c) 1989 - 1994, William LeFebvre, Northwestern University 13 * Copyright (c) 1994, 1995, William LeFebvre, Argonne National Laboratory 14 * Copyright (c) 1996, William LeFebvre, Group sys Consulting 15 * |
16 * $FreeBSD: head/contrib/top/top.c 232239 2012-02-27 20:52:20Z kib $ |
17 */ 18 19/* 20 * See the file "Changes" for information on version-to-version changes. 21 */ 22 23/* 24 * This file contains "main" and other high-level routines. --- 40 unchanged lines hidden (view full) --- 65/* imported from screen.c */ 66extern int overstrike; 67 68static int fmt_flags = 0; 69int pcpu_stats = No; 70 71/* signal handling routines */ 72sigret_t leave(); |
73sigret_t tstop(); 74#ifdef SIGWINCH 75sigret_t winch(); 76#endif 77 78volatile sig_atomic_t leaveflag; 79volatile sig_atomic_t tstopflag; 80volatile sig_atomic_t winchflag; --- 636 unchanged lines hidden (view full) --- 717 d_header = u_header; 718 d_process = u_process; 719 } 720 } 721 722 no_command = Yes; 723 if (!interactive) 724 { |
725 sleep(delay); |
726 } 727 else while (no_command) 728 { 729 /* assume valid command unless told otherwise */ 730 no_command = No; 731 732 /* set up arguments for select with timeout */ 733 FD_ZERO(&readfds); --- 429 unchanged lines hidden (view full) --- 1163 1164int status; 1165 1166{ 1167 end_screen(); 1168 exit(status); 1169 /*NOTREACHED*/ 1170} |