On Thu, May 26, 2005 at 05:24:36PM +0100, Colin Watson <[EMAIL PROTECTED]> 
wrote:
> On Sun, Feb 20, 2005 at 06:16:30PM +0100,  Marc A. Lehmann  wrote:
> > On Sun, Feb 20, 2005 at 02:27:24PM +0000, Jacob Nevins <[EMAIL PROTECTED]> 
> > wrote:
> > > This sounds to me like it might be a problem with libgtk1.2 rather
> > > than putty.
> > 
> > But it's clearly not font-related, as the badmatch is in response to a
> > XChangeProperty, at least in the dump I made.
> > 
> > > (Clearly pterm starts for some people, so there must be something
> > > specific about your situation that's breaking it.)
> > 
> > I investigated a bit more, and the problem seems to occur when another app
> > stores a non-latin1 string in the cut buffer (e.g., a string with japanese
> > characters), which changes the type of CUT_BUFFER0.
> 
> It works fine for me with pterm 0.58-1 (I tried Japanese text copied
> from a UTF-8 pterm and from a EUC-JP kterm). Would you mind re-testing?

Sure, no change, though:

Gdk-ERROR **: BadMatch (invalid parameter attributes)
     serial 59 error_code 8 request_code 18 minor_code 0

ii  pterm          0.58-1         PuTTY terminal emulator

xprop -root shows:

CUT_BUFFER3(UTF8_STRING) = 0x73, 0x69, 0x70, 0x3a, 0x30, 0x38, 0x30, 0x30,
   0x33, 0x33, 0x30, 0x31, 0x30, 0x30, 0x30, 0x40, 0x73, 0x63, 0x68, 0x6d,
   0x6f, 0x72, 0x70, 0x2e, 0x64, 0x65

Are you sure kterm and/or pterm actually do set one of the cut buffers to
non-STRING type in your tests?

Also, it should be fairly trivial, for someone who knows the code, to fix
it given the dump, without further testing.

Actually, identifiying the bug is easy even without code
knowledge: The only occurrences of XChangeProperty I could find is in
unix/gtkwin.c:init_cutbuffers, and indeed it assumes that all cut buffers
have type STRING. A BadMatch there should either be ignored (which is fine
as the only reason for the changeproperty is making sure the cut buffer is
alive) or the correct type should be used when appending (which is racy).

-- 
                The choice of a
      -----==-     _GNU_
      ----==-- _       generation     Marc Lehmann
      ---==---(_)__  __ ____  __      [EMAIL PROTECTED]
      --==---/ / _ \/ // /\ \/ /      http://schmorp.de/
      -=====/_/_//_/\_,_/ /_/\_\      XX11-RIPE


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to