[VM][UNIX][BUG] copy-paste is freezing my machine, latest SF sources
rwithers12 at attbi.com
rwithers12 at attbi.com
Sun Mar 10 09:58:27 UTC 2002
Bert,
I briefly saw your email in Celeste, then I tried to cut and paste
again. This of course locked up my machine, and I ended up losing your
email. I think it would be nice if Celeste auto-saved, or at least
offered that option.
I ended up finding the problem in getSelection. It looks like RH7.0
doesn't like XMaskEvent and it seems to block. I got it all working but
it required me to revert back to XNextEvent, per 1.22 on SF. I copy the
relevant portion below
ugh!
cheers,
Rob
here is a portion of sqXWindow.c>>getSelection which I changed back to
1.22:
do
{
if (XPending(stDisplay) == 0)
{
/* no matching event; wait for a while */
struct timeval timeout= {SELECTION_TIMEOUT, 0};
int status;
while ((status= select(FD_SETSIZE, &fdMask, 0, 0, &timeout)) <
0
&& errno == EINTR);
if (status < 0)
{
/* uh oh */
perror("select(stDisplay)");
return stEmptySelection;
}
if (status == 0)
{
/* timeout; give up */
if (isConnectedToXServer)
XBell(stDisplay, 0);
return stEmptySelection;
}
}
XNextEvent(stDisplay, &ev);
/* possible events with a mask of 0 are:
MappingNotify
ClientMessage
SelectionClear
SelectionNotify
SelectionRequest
*/
switch (ev.type)
{
/* this is necessary so that we can supply our own selection
when we
are the requestor -- this could (should) be optimised to
return the
stored selection value instead! */
case SelectionRequest:
{
sendSelection(&ev.xselectionrequest);
# ifdef USE_XSHM
if (ev.type == completionType)
--completions;
# endif
}
break;
case SelectionClear:
stOwnsSelection= 0;
break;
case MappingNotify:
XRefreshKeyboardMapping((XMappingEvent *) &ev);
break;
}
}
while (ev.type != SelectionNotify);
More information about the Squeak-dev
mailing list
|