Page MenuHomeFreeBSD

D16455.id45869.diff
No OneTemporary

D16455.id45869.diff

Index: usr.bin/top/screen.c
===================================================================
--- usr.bin/top/screen.c
+++ usr.bin/top/screen.c
@@ -54,6 +54,8 @@
static struct termios new_settings;
static char is_a_terminal = false;
+#define NON_INTERACTIVE_MODE_VIRTUAL_SCREEN_WIDTH 1024
+
void
init_termcap(bool interactive)
{
@@ -68,16 +70,17 @@
if (!interactive)
{
/* pretend we have a dumb terminal */
+ screen_width = NON_INTERACTIVE_MODE_VIRTUAL_SCREEN_WIDTH;
smart_terminal = false;
return;
}
/* assume we have a smart terminal until proven otherwise */
smart_terminal = true;
/* get the terminal name */
term_name = getenv("TERM");
/* if there is no TERM, assume it's a dumb terminal */
/* patch courtesy of Sam Horrocks at telegraph.ics.uci.edu */
if (term_name == NULL)

File Metadata

Mime Type
text/plain
Expires
Tue, May 19, 2:48 AM (7 h, 47 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33287860
Default Alt Text
D16455.id45869.diff (848 B)

Event Timeline