SHA256
1
0
forked from pool/screen

- update to current 4.0.4 git

OBS-URL: https://build.opensuse.org/package/show/Base:System/screen?expand=0&rev=48
This commit is contained in:
Michael Schröder 2013-09-13 13:59:02 +00:00 committed by Git OBS Bridge
parent f416d9cc26
commit be806c5948
10 changed files with 109 additions and 285 deletions

View File

@ -1,31 +0,0 @@
commit ae3e007da3f50e9f4e3c4244e12fce5fcd3774db
Author: Michael Schroeder <mls@suse.de>
Date: Tue Aug 7 17:05:15 2012 +0200
make ^A DEL work again
It was broken because we discarded all mapped sequences. Now we
let sequences with length 1 through to ProcessInput2.
diff --git a/src/process.c b/src/process.c
index d86c62c..bdf9355 100644
--- a/src/process.c
+++ b/src/process.c
@@ -6472,6 +6472,7 @@ int i;
{
struct action *act;
int discard = 0;
+ int keyno = i;
debug1("StuffKey #%d", i);
#ifdef DEBUG
@@ -6511,6 +6512,9 @@ int i;
if (discard && (!act || act->nr != RC_COMMAND))
{
+ /* if the input was just a single byte we let it through */
+ if (D_tcs[keyno + T_CAPS].str && strlen(D_tcs[keyno + T_CAPS].str) == 1)
+ return -1;
if (D_ESCseen)
{
D_ESCseen = 0;

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:b18a0a2227c6e486d567a4bd952b27f0cd63ed91bd485bb7c1051e9bbd771129 oid sha256:be724e27b918a1ba3172194b1082c2efb7bfa668a4f2e030d7cbdb168cee7d14
size 837276 size 846413

View File

@ -15,21 +15,8 @@ to current behavior (no polling is done).
Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Thomas Renninger <trenn@suse.de>
--- --- ./comm.c.orig 2013-09-13 13:22:50.993279658 +0000
comm.c | 3 ++- +++ ./comm.c 2013-09-13 13:23:15.264279615 +0000
comm.h.dist | 3 ++-
doc/screen.1 | 9 +++++++++
doc/screen.texinfo | 9 +++++++++
process.c | 12 ++++++++++++
screen.c | 7 +++++++
window.c | 29 ++++++++++++++++++++++++++++-
window.h | 3 +++
8 files changed, 72 insertions(+), 3 deletions(-)
Index: screen-4.0.4/comm.c
===================================================================
--- screen-4.0.4.orig/comm.c
+++ screen-4.0.4/comm.c
@@ -339,5 +339,6 @@ struct comm comms[RC_LAST + 1] = @@ -339,5 +339,6 @@ struct comm comms[RC_LAST + 1] =
#ifdef ZMODEM #ifdef ZMODEM
{ "zmodem", ARGS_012 }, { "zmodem", ARGS_012 },
@ -38,11 +25,19 @@ Index: screen-4.0.4/comm.c
+ { "zombie", ARGS_012 }, + { "zombie", ARGS_012 },
+ { "zombie_timeout", ARGS_1 } + { "zombie_timeout", ARGS_1 }
}; };
Index: screen-4.0.4/doc/screen.1 --- ./comm.h.dist.orig 2013-09-13 13:23:15.271279615 +0000
=================================================================== +++ ./comm.h.dist 2013-09-13 13:23:44.198279564 +0000
--- screen-4.0.4.orig/doc/screen.1 @@ -237,5 +237,6 @@ struct action
+++ screen-4.0.4/doc/screen.1 #define RC_XON 180
@@ -3545,6 +3545,15 @@ Optionally you can put the word \*Qonerr #define RC_ZMODEM 181
#define RC_ZOMBIE 182
+#define RC_ZOMBIE_TIMEOUT 183
-#define RC_LAST 182
+#define RC_LAST 183
--- ./doc/screen.1.orig 2013-09-13 13:22:50.993279658 +0000
+++ ./doc/screen.1 2013-09-13 13:23:15.266279615 +0000
@@ -3547,6 +3547,15 @@ Optionally you can put the word \*Qonerr
to monitor exit status of the process running in the window. If it exits normally ('0'), to monitor exit status of the process running in the window. If it exits normally ('0'),
the window disappears. Any other exit value causes the window to become a zombie. the window disappears. Any other exit value causes the window to become a zombie.
@ -58,11 +53,9 @@ Index: screen-4.0.4/doc/screen.1
.SH "THE MESSAGE LINE" .SH "THE MESSAGE LINE"
.I Screen .I Screen
displays informational messages and other diagnostics in a \fImessage line\fP. displays informational messages and other diagnostics in a \fImessage line\fP.
Index: screen-4.0.4/doc/screen.texinfo --- ./doc/screen.texinfo.orig 2013-09-13 13:22:50.985279658 +0000
=================================================================== +++ ./doc/screen.texinfo 2013-09-13 13:23:15.268279615 +0000
--- screen-4.0.4.orig/doc/screen.texinfo @@ -1239,6 +1239,8 @@ Send an XON character. @xref{XON/XOFF}.
+++ screen-4.0.4/doc/screen.texinfo
@@ -1238,6 +1238,8 @@ Send an XON character. @xref{XON/XOFF}.
Define how screen treats zmodem requests. @xref{Zmodem}. Define how screen treats zmodem requests. @xref{Zmodem}.
@item zombie [@var{keys} [onerror] ] @item zombie [@var{keys} [onerror] ]
Keep dead windows. @xref{Zombie}. Keep dead windows. @xref{Zombie}.
@ -71,7 +64,7 @@ Index: screen-4.0.4/doc/screen.texinfo
@end table @end table
@node New Window, Selecting, Commands, Top @node New Window, Selecting, Commands, Top
@@ -5222,6 +5224,8 @@ Display the version and modification dat @@ -5223,6 +5225,8 @@ Display the version and modification dat
@section Zombie @section Zombie
@deffn Command zombie [@var{keys} [onerror] ] @deffn Command zombie [@var{keys} [onerror] ]
@deffnx Command defzombie [@var{keys}] @deffnx Command defzombie [@var{keys}]
@ -80,7 +73,7 @@ Index: screen-4.0.4/doc/screen.texinfo
(none)@* (none)@*
Per default windows are removed from the window list as soon as the Per default windows are removed from the window list as soon as the
windows process (e.g. shell) exits. When a string of two keys is windows process (e.g. shell) exits. When a string of two keys is
@@ -5241,6 +5245,11 @@ Optionally you can put the word @code{on @@ -5242,6 +5246,11 @@ Optionally you can put the word @code{on
cause screen to monitor exit status of the process running in the window. cause screen to monitor exit status of the process running in the window.
If it exits normally ('0'), the window disappears. Any other exit value If it exits normally ('0'), the window disappears. Any other exit value
causes the window to become a zombie. causes the window to become a zombie.
@ -92,10 +85,8 @@ Index: screen-4.0.4/doc/screen.texinfo
@end deffn @end deffn
@node Printcmd, Rendition, Zombie, Miscellaneous @node Printcmd, Rendition, Zombie, Miscellaneous
Index: screen-4.0.4/process.c --- ./process.c.orig 2013-09-13 13:22:50.994279658 +0000
=================================================================== +++ ./process.c 2013-09-13 13:23:15.270279615 +0000
--- screen-4.0.4.orig/process.c
+++ screen-4.0.4/process.c
@@ -3067,6 +3067,18 @@ int key; @@ -3067,6 +3067,18 @@ int key;
} }
WindowChanged((struct win *)0, 0); WindowChanged((struct win *)0, 0);
@ -115,10 +106,8 @@ Index: screen-4.0.4/process.c
case RC_SILENCE: case RC_SILENCE:
n = fore->w_silence != 0; n = fore->w_silence != 0;
i = fore->w_silencewait; i = fore->w_silencewait;
Index: screen-4.0.4/screen.c --- ./screen.c.orig 2013-09-13 13:22:50.989279658 +0000
=================================================================== +++ ./screen.c 2013-09-13 13:23:15.270279615 +0000
--- screen-4.0.4.orig/screen.c
+++ screen-4.0.4/screen.c
@@ -1557,6 +1557,13 @@ int wstat_valid; @@ -1557,6 +1557,13 @@ int wstat_valid;
p->w_y = MFindUsedLine(p, p->w_bot, 1); p->w_y = MFindUsedLine(p, p->w_bot, 1);
sprintf(buf, "\n\r=== Command %s (%s) ===", reason, s ? s : "?"); sprintf(buf, "\n\r=== Command %s (%s) ===", reason, s ? s : "?");
@ -133,10 +122,8 @@ Index: screen-4.0.4/screen.c
WindowChanged(p, 'f'); WindowChanged(p, 'f');
} }
else else
Index: screen-4.0.4/window.c --- ./window.c.orig 2013-09-13 13:22:50.990279658 +0000
=================================================================== +++ ./window.c 2013-09-13 13:23:15.270279615 +0000
--- screen-4.0.4.orig/window.c
+++ screen-4.0.4/window.c
@@ -87,6 +87,7 @@ static int DoAutolf __P((char *, int *, @@ -87,6 +87,7 @@ static int DoAutolf __P((char *, int *,
static void ZombieProcess __P((char **, int *)); static void ZombieProcess __P((char **, int *));
static void win_readev_fn __P((struct event *, char *)); static void win_readev_fn __P((struct event *, char *));
@ -163,7 +150,7 @@ Index: screen-4.0.4/window.c
#undef COMPOSE #undef COMPOSE
} }
@@ -838,6 +841,14 @@ struct NewWindow *newwin; @@ -842,6 +845,14 @@ struct NewWindow *newwin;
DoStartLog(p, buf, sizeof(buf)); DoStartLog(p, buf, sizeof(buf));
} }
@ -178,7 +165,7 @@ Index: screen-4.0.4/window.c
p->w_readev.fd = p->w_writeev.fd = p->w_ptyfd; p->w_readev.fd = p->w_writeev.fd = p->w_ptyfd;
p->w_readev.type = EV_READ; p->w_readev.type = EV_READ;
p->w_writeev.type = EV_WRITE; p->w_writeev.type = EV_WRITE;
@@ -1060,6 +1071,7 @@ struct win *wp; @@ -1064,6 +1075,7 @@ struct win *wp;
evdeq(&wp->w_readev); /* just in case */ evdeq(&wp->w_readev); /* just in case */
evdeq(&wp->w_writeev); /* just in case */ evdeq(&wp->w_writeev); /* just in case */
evdeq(&wp->w_silenceev); evdeq(&wp->w_silenceev);
@ -186,7 +173,7 @@ Index: screen-4.0.4/window.c
evdeq(&wp->w_destroyev); evdeq(&wp->w_destroyev);
#ifdef COPY_PASTE #ifdef COPY_PASTE
FreePaster(&wp->w_paster); FreePaster(&wp->w_paster);
@@ -1941,6 +1953,21 @@ char *data; @@ -1945,6 +1957,21 @@ char *data;
return; return;
} }
@ -208,10 +195,8 @@ Index: screen-4.0.4/window.c
static void static void
win_writeev_fn(ev, data) win_writeev_fn(ev, data)
Index: screen-4.0.4/window.h --- ./window.h.orig 2013-09-13 13:22:50.990279658 +0000
=================================================================== +++ ./window.h 2013-09-13 13:23:15.270279615 +0000
--- screen-4.0.4.orig/window.h
+++ screen-4.0.4/window.h
@@ -57,6 +57,7 @@ struct NewWindow @@ -57,6 +57,7 @@ struct NewWindow
int encoding; int encoding;
char *hstatus; char *hstatus;
@ -229,15 +214,3 @@ Index: screen-4.0.4/window.h
int w_ptyfd; /* fd of the master pty */ int w_ptyfd; /* fd of the master pty */
char w_inbuf[IOSIZE]; char w_inbuf[IOSIZE];
int w_inlen; int w_inlen;
Index: screen-4.0.4/comm.h.dist
===================================================================
--- screen-4.0.4.orig/comm.h.dist
+++ screen-4.0.4/comm.h.dist
@@ -236,5 +236,6 @@ struct action
#define RC_XON 179
#define RC_ZMODEM 180
#define RC_ZOMBIE 181
+#define RC_ZOMBIE_TIMEOUT 182
-#define RC_LAST 181
+#define RC_LAST 182

View File

@ -1,3 +1,17 @@
-------------------------------------------------------------------
Fri Sep 13 15:17:12 CEST 2013 - mls@suse.de
- update to current 4.0.4 git to get support for non-bmp unicode
* remove no longer needed mappedcmd.diff
* remove no longer needed styroptcrash.diff
- fix potential buffer overrun in show_all_active.patch
- redo combine screen_enhance_windows_list_1_3.patch,
screen_enhance_windows_list_2_3.patch,
screen_fix_wW_string_escapes_to_nearly_old_behavior.patch
into screen_enhance_windows_list.patch.
Do not mess with the old %w behaviour, just add support for the
windows command argument. Fixes bnc#808565.
------------------------------------------------------------------- -------------------------------------------------------------------
Sun Mar 24 10:57:09 UTC 2013 - trenn@suse.de Sun Mar 24 10:57:09 UTC 2013 - trenn@suse.de

View File

@ -45,14 +45,10 @@ Patch3: screen-4.0.3-ipv6.patch
Patch4: term_too_long.diff Patch4: term_too_long.diff
Patch5: sort_command.patch Patch5: sort_command.patch
Patch6: libtinfo.diff Patch6: libtinfo.diff
Patch7: mappedcmd.diff
Patch8: styroptcrash.diff
Patch9: use_locale.diff Patch9: use_locale.diff
Patch10: screen-poll-zombies.patch Patch10: screen-poll-zombies.patch
Patch11: screen_enhance_windows_list_1_3.patch Patch11: show_all_active.patch
Patch12: screen_enhance_windows_list_2_3.patch Patch12: screen_enhance_windows_list.patch
Patch13: show_all_active.patch
Patch14: screen_fix_wW_string_escapes_to_nearly_old_behavior.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description %description
@ -71,14 +67,10 @@ Documentation: man page
%patch4 -p1 %patch4 -p1
%patch5 %patch5
%patch6 %patch6
%patch7 -p2
%patch8 -p2
%patch9 -p1 %patch9 -p1
%patch10 -p1 %patch10 -p1
%patch11 -p1 %patch11
%patch12 -p1 %patch12
%patch13 -p1
%patch14 -p1
%build %build
CFLAGS="-DMAXWIN=1000 $RPM_OPT_FLAGS" %configure --prefix=/usr --infodir=%{_infodir} \ CFLAGS="-DMAXWIN=1000 $RPM_OPT_FLAGS" %configure --prefix=/usr --infodir=%{_infodir} \

View File

@ -1,9 +1,7 @@
screen: Introduce windows command screen: Introduce argument to windows command
This new command is doing nearly the same as the windows A string escape can be passed which makes the windows command
command. much more flexible. The default string escape if no argument
But a string escape can be passed which makes it much
more flexible. The default string escape if no argument
is passed is "%n%f %t " which is intended to rebuild is passed is "%n%f %t " which is intended to rebuild
the same output the windows command would give as good the same output the windows command would give as good
as possible (slight changes with the flags can happen). as possible (slight changes with the flags can happen).
@ -17,17 +15,9 @@ window list status of an active screen session from
shell). shell).
Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Thomas Renninger <trenn@suse.de>
---
src/comm.c | 2 +-
src/doc/screen.1 | 5 ++++-
src/doc/screen.texinfo | 7 ++++++-
src/process.c | 35 ++++++++++++++++++++++++++++++++++-
4 files changed, 45 insertions(+), 4 deletions(-)
diff --git a/comm.c b/comm.c --- ./comm.c.orig 2013-09-13 13:37:01.440278153 +0000
index 8722ca8..b8b535f 100644 +++ ./comm.c 2013-09-13 13:37:21.830278117 +0000
--- a/comm.c
+++ b/comm.c
@@ -328,7 +328,7 @@ struct comm comms[RC_LAST + 1] = @@ -328,7 +328,7 @@ struct comm comms[RC_LAST + 1] =
{ "wall", NEED_DISPLAY|ARGS_1}, { "wall", NEED_DISPLAY|ARGS_1},
{ "width", ARGS_0123 }, { "width", ARGS_0123 },
@ -37,11 +27,9 @@ index 8722ca8..b8b535f 100644
{ "wrap", NEED_FORE|ARGS_01 }, { "wrap", NEED_FORE|ARGS_01 },
#ifdef COPY_PASTE #ifdef COPY_PASTE
{ "writebuf", ARGS_0123 }, { "writebuf", ARGS_0123 },
diff --git a/doc/screen.1 b/doc/screen.1 --- ./doc/screen.1.orig 2013-09-13 13:39:15.327277916 +0000
index 4e72f8b..7a0c1de 100644 +++ ./doc/screen.1 2013-09-13 13:38:46.391277967 +0000
--- a/doc/screen.1 @@ -3435,7 +3435,7 @@ settings).
+++ b/doc/screen.1
@@ -3430,7 +3430,7 @@ settings).
and 6 characters high in order to display. and 6 characters high in order to display.
.sp .sp
.ne 3 .ne 3
@ -50,7 +38,7 @@ index 4e72f8b..7a0c1de 100644
.PP .PP
Uses the message line to display a list of all the windows. Uses the message line to display a list of all the windows.
Each window is listed by number with the name of process that has been Each window is listed by number with the name of process that has been
@@ -3446,6 +3446,9 @@ windows occupied by other users are marked with `&'; @@ -3451,6 +3451,9 @@ windows occupied by other users are mark
windows in the zombie state are marked with `Z'. windows in the zombie state are marked with `Z'.
If this list is too long to fit on the terminal's status line only the If this list is too long to fit on the terminal's status line only the
portion around the current window is displayed. portion around the current window is displayed.
@ -60,11 +48,9 @@ index 4e72f8b..7a0c1de 100644
.sp .sp
.ne 3 .ne 3
.BR "wrap " [ on | off ] .BR "wrap " [ on | off ]
diff --git a/doc/screen.texinfo b/doc/screen.texinfo --- ./doc/screen.texinfo.orig 2013-09-13 13:38:53.376277955 +0000
index e564abe..e7a693d 100644 +++ ./doc/screen.texinfo 2013-09-13 13:39:47.392277859 +0000
--- a/doc/screen.texinfo @@ -2617,7 +2617,7 @@ before displaying a message. Default is
+++ b/doc/screen.texinfo
@@ -2613,7 +2613,7 @@ before displaying a message. Default is 30 seconds.
@section Windows @section Windows
@kindex w @kindex w
@kindex C-w @kindex C-w
@ -73,7 +59,7 @@ index e564abe..e7a693d 100644
(@kbd{C-a w}, @kbd{C-a C-w})@* (@kbd{C-a w}, @kbd{C-a C-w})@*
Uses the message line to display a list of all the windows. Each Uses the message line to display a list of all the windows. Each
window is listed by number with the name of the program running in the window is listed by number with the name of the program running in the
@@ -2632,6 +2632,11 @@ windows in the zombie state are marked with @samp{Z}. @@ -2636,6 +2636,11 @@ windows in the zombie state are marked w
If this list is too long to fit on the terminal's status line only the If this list is too long to fit on the terminal's status line only the
portion around the current window is displayed. portion around the current window is displayed.
@ -85,56 +71,51 @@ index e564abe..e7a693d 100644
@end deffn @end deffn
@node Hardstatus, Mousetrack, Windows, Window Settings @node Hardstatus, Mousetrack, Windows, Window Settings
diff --git a/process.c b/process.c --- ./process.c.orig 2013-09-13 13:39:55.192277845 +0000
index 7370924..79e82b5 100644 +++ ./process.c 2013-09-13 13:53:18.672276423 +0000
--- a/process.c @@ -170,6 +170,7 @@ static void ResizeFin __P((char *, int,
+++ b/process.c static struct action *FindKtab __P((char *, int));
@@ -1838,7 +1838,12 @@ int key; static void SelectFin __P((char *, int, char *));
static void SelectLayoutFin __P((char *, int, char *));
+static void ShowWindowsX __P((char *));
extern struct layer *flayer;
@@ -1838,6 +1839,11 @@ int key;
Activate(-1); Activate(-1);
break; break;
case RC_WINDOWS: case RC_WINDOWS:
- ShowWindows(-1); + if (args[0])
+ if (args[0]) { + {
+ s = SaveStr(args[0]); + ShowWindowsX(args[0]);
+ ShowWindowsX(s); + break;
+ } + }
+ else ShowWindows(-1);
+ ShowWindows(-1);
break; break;
case RC_VERSION: case RC_VERSION:
OutputMsg(0, "screen %s", version); @@ -5637,6 +5643,25 @@ int where;
@@ -5605,6 +5610,34 @@ struct win *p; Msg(0, "%s", ss);
return s;
} }
+/* +/*
+ * String Escape based windows listing + * String Escape based windows listing
+ * Unfortunately it is not possible to rebuild the exact + * mls: currently does a Msg() call for each(!) window, dunno why
+ * output (flags) from ShowWindows() with a default
+ * string escape. But when there should be a new screen
+ * version where slight output changes get accepted,
+ * ShowWindowsX() should replace the rather static
+ * (in output and size) old ShowWindows() and AddWindows()
+ * functions
+ */ + */
+void +static void
+ShowWindowsX(char *string) +ShowWindowsX(str)
+char *str;
+{ +{
+ int i; + int i;
+ char *s = "";
+
+ debug1("ShowWindowsX: string [%s]", string); + debug1("ShowWindowsX: string [%s]", string);
+
+ for (i = 0; i < maxwin ; i++) + for (i = 0; i < maxwin ; i++)
+ { + {
+ if (wtab[i] == NULL) + if (!wtab[i])
+ continue; + continue;
+ + Msg(0, "%s", MakeWinMsg(str, wtab[i], '%'));
+ s = MakeWinMsg(string, wtab[i], '%');
+ Msg(0, "%s", s);
+ } + }
+} +}
+ +
void +
ShowWindows(where) static void
int where; ShowInfo()
{

View File

@ -1,60 +0,0 @@
screen: Remove foreground and other window marking workaround
and place it where it always should have been in the generic AddWindowsFlag
function.
The actual implementation when this workaround was added is beyond git
history. This was needed to implement a very specific String Escape (wW)
function:
w all window numbers and names. With '-' quailifier: up to the
current window; with '+' qualifier: starting with the window
after the current one.
W all window numbers and names except the current one
But adding all windows to a String Escape does not make much sense and
may only fit for a very specific special case.
Better clean up the code, whoever needed wW String Escapes can use windows
command nowadays.
Later the whole wW String Escape should vanish in favor for the
String Escaped windows command which can do the same but much more flexible.
Signed-off-by: Thomas Renninger <trenn@suse.de>
Index: screen-4.0.4/process.c
===================================================================
---
src/process.c | 6 ------
1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/process.c b/process.c
index bbc46e6..7370924 100644
--- a/process.c
+++ b/process.c
@@ -5507,12 +5507,8 @@ int where;
AddWinMsgRend(s, rend);
sprintf(s, "%d", p->w_number);
s += strlen(s);
- if (display && p == D_fore)
- *s++ = '*';
if (!(flags & 2))
{
- if (display && p == D_other)
- *s++ = '-';
s = AddWindowFlags(s, len, p);
}
*s++ = ' ';
@@ -5537,12 +5533,10 @@ struct win *p;
*s = 0;
return s;
}
-#if 0
if (display && p == D_fore)
*s++ = '*';
if (display && p == D_other)
*s++ = '-';
-#endif
if (p->w_layer.l_cvlist && p->w_layer.l_cvlist->c_lnext)
*s++ = '&';
if (p->w_monitor == MON_DONE

View File

@ -1,19 +0,0 @@
From: Thomas Renninger <trenn@suse.de>
References: bnc#808565
Subject: Fix old wW string escapes behavior to what previously was %Lw
Signed-off-by: Thomas Renninger <trenn@suse.de>
Index: screen-4.0.4/screen.c
===================================================================
--- screen-4.0.4.orig/screen.c
+++ screen-4.0.4/screen.c
@@ -2780,7 +2780,7 @@ int rec;
oldfore = D_fore;
D_fore = win;
}
- ss = AddWindows(p, l - 1, (*s == 'w' ? 0 : 1) | (longflg ? 0 : 2) | (plusflg ? 4 : 0) | (minusflg ? 8 : 0), win ? win->w_number : -1);
+ ss = AddWindows(p, l - 1, (*s == 'w' ? 0 : 1) | (plusflg ? 4 : 0) | (minusflg ? 8 : 0), win ? win->w_number : -1);
if (display)
D_fore = oldfore;
}

View File

@ -5,11 +5,9 @@ each window is shown.
Signed-off-by: Thomas Renninger <trenn@suse.de> Signed-off-by: Thomas Renninger <trenn@suse.de>
diff --git a/doc/screen.1 b/doc/screen.1 --- ./doc/screen.1.orig 2013-09-13 13:26:28.055279274 +0000
index 7a0c1de..57352f1 100644 +++ ./doc/screen.1 2013-09-13 13:26:41.385279250 +0000
--- a/doc/screen.1 @@ -3747,6 +3747,10 @@ window; with '+' qualifier: starting wit
+++ b/doc/screen.1
@@ -3750,6 +3750,10 @@ window; with '+' qualifier: starting with the window after the current
one. one.
.IP W .IP W
all window numbers and names except the current one all window numbers and names except the current one
@ -20,29 +18,24 @@ index 7a0c1de..57352f1 100644
.IP y .IP y
last two digits of the year number last two digits of the year number
.IP Y .IP Y
diff --git a/screen.c b/screen.c --- ./screen.c.orig 2013-09-13 13:26:28.057279274 +0000
index efb73d3..e8a553c 100644 +++ ./screen.c 2013-09-13 13:34:30.151278421 +0000
--- a/screen.c @@ -2693,6 +2693,20 @@ int rec;
+++ b/screen.c
@@ -2681,6 +2681,23 @@ int rec;
} }
p += strlen(p) - 1; p += strlen(p) - 1;
break; break;
+ case 'X': case 'x': + case 'X': case 'x':
+ if (!win) + *p = 0;
+ break; + for (i = 0; win && win->w_cmdargs[i]; i++)
+ if (win->w_cmdargs[0]) { + {
+ sprintf(p, "%s", win->w_cmdargs[0]); + if (l < strlen(win->w_cmdargs[i]) + 1)
+ p += strlen(p); + break;
+ } + sprintf(p, i ? "%s" : " %s", win->w_cmdargs[i]);
+ else + l -= strlen(p);
+ break;
+ if (*s == 'x') {
+ for (i = 1; win->w_cmdargs[i]; i++) {
+ sprintf(p, " %s", win->w_cmdargs[i]);
+ p += strlen(p); + p += strlen(p);
+ if (i == 0 && *s == 'X')
+ break;
+ } + }
+ }
+ p--; + p--;
+ break; + break;
case 'l': case 'l':

View File

@ -1,19 +0,0 @@
commit c64f800e7b197e14433ac97be12f32385a27a04f
Author: Michael Schroeder <mls@suse.de>
Date: Wed Aug 8 19:54:11 2012 +0200
extend commit #8c1b8e45, which fixed -x but forgot about -r
diff --git a/src/screen.c b/src/screen.c
index 949df01..6e19732 100644
--- a/src/screen.c
+++ b/src/screen.c
@@ -988,7 +988,7 @@ char **av;
Panic(0, "$HOME too long - sorry.");
attach_tty = "";
- if (!detached && !lsflag && !cmdflag && !(dflag && !mflag && !rflag && !xflag) && !(!mflag && !SockMatch && sty && !xflag))
+ if (!detached && !lsflag && !cmdflag && !(dflag && !mflag && !rflag && !xflag) && !(sty && !SockMatch && !mflag && !rflag && !xflag))
{
#ifndef NAMEDPIPE
int fl;