Changeset View
Changeset View
Standalone View
Standalone View
usr.bin/top/display.c
Show First 20 Lines • Show All 1,316 Lines • ▼ Show 20 Lines | i_uptime(struct timeval *bt, time_t *tod) | ||||
else | else | ||||
{ | { | ||||
fputs(" ", stdout); | fputs(" ", stdout); | ||||
} | } | ||||
printf(" up %d+%02d:%02d:%02d", days, hrs, mins, secs); | printf(" up %d+%02d:%02d:%02d", days, hrs, mins, secs); | ||||
} | } | ||||
} | } | ||||
void | |||||
i_battery(int nbat, int batt) | |||||
{ | |||||
if (nbat > 0) { | |||||
philip: Follow the style of the rest of the file please. | |||||
printf("; battery: %d%%", batt); | |||||
} | |||||
} | |||||
#define SETUPBUFFER_MIN_SCREENWIDTH 80 | #define SETUPBUFFER_MIN_SCREENWIDTH 80 | ||||
#define SETUPBUFFER_REQUIRED_ADDBUFSIZ 2 | #define SETUPBUFFER_REQUIRED_ADDBUFSIZ 2 | ||||
static char * | static char * | ||||
setup_buffer(char *buffer, int addlen) | setup_buffer(char *buffer, int addlen) | ||||
{ | { | ||||
size_t len, old_len; | size_t len, old_len; | ||||
char *new_buffer; | char *new_buffer; | ||||
Show All 22 Lines |
Follow the style of the rest of the file please.