From: root Date: Tue, 28 Oct 2008 04:45:58 +0000 (+0000) Subject: *** empty log message *** X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=0c975cc098f87f00243c5732083571f477f24d46;p=dana%2Furxvt.git *** empty log message *** --- diff --git a/Changes b/Changes index ffa5fddc..888377aa 100644 --- a/Changes +++ b/Changes @@ -21,6 +21,8 @@ DUMB: support tex fonts TODO: /*TODO: the xlceararea/xfillrectangle below don't take scroll offste into account, ask mikachu for details */ +TODO: investgate wm resize race: while sleep 0.001; do printf "\033[?30l";sleep 0.001;printf "\033[?30h";done +TODO: investigate miroslav patches TODO: artificially enlargen wide characters at end to correctly cut&paste. TODO: cursor over overlays, when focus change? - remove bogus "setuid/setgid security issues" from rxvt.1.pod, they @@ -31,6 +33,8 @@ TODO: cursor over overlays, when focus change? - ignore byte-order marks and do not treat them like combining characters. - fix build issue when CURSOR_BLINK is not defined (Emanuele Giaquinta). - do some µ-optimisations to the character fast path. + - use a less cunning, but more robust algorithm to avoid one terminal + monopolising the whole process by outputting a lot of text. - try to work around linux first breaking sched_yield and now breaking the only known workaround. diff --git a/src/command.C b/src/command.C index ce5084d9..b68b43ad 100644 --- a/src/command.C +++ b/src/command.C @@ -1193,9 +1193,8 @@ rxvt_term::pty_cb (ev::io &w, int revents) if (revents & ev::READ) // loop, but don't allow a single term to monopolize us - while (pty_fill ()) - if (cmd_parse ()) - break; + for (int i = CBUFCNT; i-- && pty_fill (); ) + cmd_parse (); if (revents & ev::WRITE) pty_write (); @@ -2187,10 +2186,9 @@ rxvt_term::button_release (XButtonEvent &ev) /*}}} */ -bool +void rxvt_term::cmd_parse () { - bool flag = false; wchar_t ch = NOCHAR; char *seq_begin; // remember start of esc-sequence here @@ -2294,11 +2292,9 @@ rxvt_term::cmd_parse () */ if (refreshnow) { - flag = true; scr_refresh (); want_refresh = 1; } - } else { @@ -2316,8 +2312,6 @@ rxvt_term::cmd_parse () ch = NOCHAR; } } - - return flag; } // read the next character diff --git a/src/rxvt.h b/src/rxvt.h index 7a7cf35f..ce8b3fbc 100644 --- a/src/rxvt.h +++ b/src/rxvt.h @@ -552,6 +552,7 @@ enum { #define IMBUFSIZ 128 // input modifier buffer sizes #define KBUFSZ 512 // size of keyboard mapping buffer #define CBUFSIZ 2048 // size of command buffer +#define CBUFCNT 8 // never call pty_fill/cmd_parse more than this often in a row #define UBUFSIZ 2048 // character buffer #if ENABLE_FRILLS @@ -1194,7 +1195,7 @@ struct rxvt_term : zero_initialized, rxvt_vars, rxvt_screen { uint32_t next_octet () NOTHROW; uint32_t cmd_get8 () THROW ((class out_of_input)); - bool cmd_parse (); + void cmd_parse (); void mouse_report (XButtonEvent &ev); void button_press (XButtonEvent &ev); void button_release (XButtonEvent &ev);