Re: pine/pico vt control characters bug

From: der Mouse (mouseat_private)
Date: Sat Apr 25 1998 - 15:26:21 PDT

  • Next message: Matt Barrie: "Re: feature Re: pine/pico vt control characters bug"

    > Pico, an editor included with pine 3.96 package, handles vt control
    > characters (eg. 0x9B) improperly, so it's possible to do almost
    > anything when normal text file is viewed with pico.
    
    This depends entirely on the terminal (or emulator) in use; I just now
    tried sending 0x9b 0x63 to one of my windows and got a greater-or-equal
    sign and a lowercase c, nothing odd at all.
    
    > -    else if (c.c < 0x20 || c.c == 0x7F) {
    > +    else if (c.c < 0x20 || c.c == 0x7F || c.c == 0x9B) {
    
    If you're going to blindly assume 00-20, 7f, and 9b, you probably want
    to hit all of C1 space as well, as in
    
    +    else if (c.c < 0x20 || (c.c >= 0x7F && c.c <= 0x9F)) {
    
    (I'm assuming c.c is a specifically unsigned char, or something wider
    than a char, or the "< 0x20" test breaks the whole high half anyway).
    
                                            der Mouse
    
                                   mouseat_private
                         7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B
    



    This archive was generated by hypermail 2b30 : Fri Apr 13 2001 - 13:51:17 PDT