From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,19e9a668e7d327ae,start X-Google-Attributes: gidfee84,public From: jtk@atria.com (John Kohl) Subject: Bug fixes for DEC Alpha OSF/1 emacs 19.29 Date: 1995/06/27 Message-ID: X-Deja-AN: 105131006 sender: news@atria.com organization: Atria Software, Inc. newsgroups: comp.unix.osf.osf1 There is one bug and one misfeature I consider a bug in emacs-19.29 relating to DEC Alpha support. 1) If BSD ptys are not in use, emacs is unable to open any ptys for subprocesses. There's a system routine "openpty()" which knows how to find a pty. Attached below are diffs to use openpty(). 2) Meta-SPC is being interpreted as the introduction of a character composition, due to the vagaries of the system X11 libraries. I consider this a bug because hitting the meta and space keys on my keyboard should make emacs execute the function bound to M-SPC. Attached below is a diff. ==John Kohl diffs 1: fix to use openpty() =================================================================== RCS file: m/RCS/alpha.h,v retrieving revision 1.1 diff -c -r1.1 m/alpha.h *** 1.1 1995/06/27 16:13:50 --- m/alpha.h 1995/06/27 16:22:58 *************** *** 259,261 **** --- 259,271 ---- #endif /* not THIS_IS_YMAKEFILE */ #endif /* not NOT_C_CODE */ + + #define PTY_ITERATION for (i = 0; i < 1; i++) /* ick */ + #define PTY_NAME_SPRINTF /* none */ + #define PTY_TTY_NAME_SPRINTF /* none */ + #define PTY_OPEN { \ + int dummy; \ + if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) \ + fd = -1; \ + close(dummy); \ + } =================================================================== RCS file: RCS/process.c,v retrieving revision 1.1 diff -c -r1.1 process.c *** 1.1 1995/06/27 16:05:49 --- process.c 1995/06/27 16:15:39 *************** *** 395,401 **** #endif /* no PTY_NAME_SPRINTF */ #ifdef PTY_OPEN ! PTY_OPEN; #else /* no PTY_OPEN */ #ifdef IRIS /* Unusual IRIS code */ --- 395,401 ---- #endif /* no PTY_NAME_SPRINTF */ #ifdef PTY_OPEN ! PTY_OPEN #else /* no PTY_OPEN */ #ifdef IRIS /* Unusual IRIS code */ 2) diffs #2: fix for M-SPC: =================================================================== RCS file: RCS/xterm.c,v retrieving revision 1.1 diff -c -r1.1 xterm.c *** 1.1 1995/06/27 15:33:18 --- xterm.c 1995/06/27 16:37:18 *************** *** 3597,3602 **** --- 3597,3603 ---- if (f != 0) { KeySym keysym, orig_keysym; + struct x_display_info *dpyinfo = FRAME_X_DISPLAY_INFO (f); /* al%imercury@uunet.uu.net says that making this 81 instead of 80 fixed a bug whereby meta chars made his Emacs hang. */ unsigned char copy_buffer[81]; *************** *** 3603,3609 **** int modifiers; event.xkey.state ! |= x_emacs_to_x_modifiers (FRAME_X_DISPLAY_INFO (f), extra_keyboard_modifiers); modifiers = event.xkey.state; --- 3604,3610 ---- int modifiers; event.xkey.state ! |= x_emacs_to_x_modifiers (dpyinfo, extra_keyboard_modifiers); modifiers = event.xkey.state; *************** *** 3611,3617 **** --- 3612,3630 ---- /* make_lispy_event turns chars into control chars. Don't do it here because XLookupString is too eager. */ + #ifdef OSF1 + /* OSF/1 XLookupString is also too eager with + certain meta/alt bits, particularly for thinks like + Meta-SPC which will start compose character processing + if you don't mask out the meta stuff. */ + event.xkey.state &= ~(ControlMask | + dpyinfo->meta_mod_mask | + dpyinfo->alt_mod_mask | + dpyinfo->super_mod_mask | + dpyinfo->hyper_mod_mask); + #else event.xkey.state &= ~ControlMask; + #endif nbytes = XLookupString (&event.xkey, copy_buffer, 80, &keysym, &compose_status); *************** *** 3692,3698 **** bufp->code = keysym; XSETFRAME (bufp->frame_or_window, f); bufp->modifiers ! = x_x_to_emacs_modifiers (FRAME_X_DISPLAY_INFO (f), modifiers); bufp->timestamp = event.xkey.time; bufp++; --- 3705,3711 ---- bufp->code = keysym; XSETFRAME (bufp->frame_or_window, f); bufp->modifiers ! = x_x_to_emacs_modifiers (dpyinfo, modifiers); bufp->timestamp = event.xkey.time; bufp++; *************** *** 3712,3718 **** bufp->code = copy_buffer[i]; XSETFRAME (bufp->frame_or_window, f); bufp->modifiers ! = x_x_to_emacs_modifiers (FRAME_X_DISPLAY_INFO (f), modifiers); bufp->timestamp = event.xkey.time; bufp++; --- 3725,3731 ---- bufp->code = copy_buffer[i]; XSETFRAME (bufp->frame_or_window, f); bufp->modifiers ! = x_x_to_emacs_modifiers (dpyinfo, modifiers); bufp->timestamp = event.xkey.time; bufp++; -- John Kohl or working for but not representing: Atria Software sometimes hacking on: NetBSD/i386