Closed Bug 52142 Opened 24 years ago Closed 24 years ago

existence of XIM will crash mozilla in startup

Categories

(Core :: Internationalization, defect, P2)

HP
HP-UX
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: shanjian, Assigned: shanjian)

References

Details

(Keywords: inputmethod, Whiteboard: nsbeta3+, fix checked in)

Attachments

(2 files)

Login through CDE and choose a japanese locale. When system prompt for IM, select XIM or ATOK.
You will hit a bus error before mozilla bring up any window.
call stack shows the crash happens inside gdk call: gdk_im_begin.
I am wondering if this is a gtk/gdk problem on HPUX. I need to find 
a verification application to verify this.
Blocks: 52139
To be more specific, this crash happen when using on-the-spot input method
style. As suggested by toshi, putting 
user_pref("xin.input_style", "over-the-spot"); 
into prefs.js will provide a temporary workaround. Lower its severity.
Severity: blocker → critical
We have 4 kinds of input style available on X, They are "on-the-spot",
"over-the-spot", "separate", "none". Input style can be further defined
using preedit style and status style. From my testing, "over-the-spot" is
the only input style working on HP at this time. ( I did not test various
combination of preedit and status style.)

Since "on-the-spot" is the default IME style, I would suggest to check in
following fix to stop crash:

Index: nsGtkIMEHelper.cpp
===================================================================
RCS file: /cvsroot/mozilla/widget/src/gtk/nsGtkIMEHelper.cpp,v
retrieving revision 1.14
diff -r1.14 nsGtkIMEHelper.cpp
1150a1151,1167
> #ifdef HPUX
>   prefered_preedit_style = (GdkIMStyle) GDK_IM_PREEDIT_POSITION;
>   prefered_status_style = (GdkIMStyle) GDK_IM_STATUS_NOTHING;
>   style = gdk_im_decide_style((GdkIMStyle)(prefered_preedit_style |
prefered_status_style));
>   if (style) {
>     gInputStyle = style;
>   } else {
>     style = gdk_im_decide_style((GdkIMStyle) (SUPPORTED_PREEDIT |
SUPPORTED_STATUS));
>     if (style) {
>       gInputStyle = style;
>     } else {
>       gInputStyle = (GdkIMStyle)(GDK_IM_PREEDIT_NONE|GDK_IM_STATUS_NONE);
>     }
>   }
>   return gInputStyle;
> #endif
>

nominate nsbeta3
Keywords: nsbeta3
add tajima san to the cc list
shanjian- please provide context diff. no one know where you want to put that 
part of code into the file.
tajima- please review the code. 
shanjian- you need to follow the new review rule. Read tinderbox for details.


Shanjian's patch seems to be okay as far as whole codes are ifdefed for hpux
only and hp agrees that on-the-spot does not work well with their XIMs. Another
comment is, GDK_IM_STATUS_AREA might be preferable to GDK_IM_STATUS_NOTHING
if that combination works.

nsbeta3+ since this is low risk for other platform. Please do the proper new 
code review and approval process before check in.
Whiteboard: nsbeta3+
Status: UNCONFIRMED → NEW
Ever confirmed: true
Just comfirm the bug.
This is a P2 for HP-UX. 
Priority: P3 → P2
Shanjian, I'm reviewing the proposed patch, but it seems to me that it
should be enough to change primary inputstyle to over-the-spot
for hpux, since the rest of the codes inside ifdef HPUX is duplicated to
the original. I'm going to attach a new code diff, which I tested on linux
and Solaris.
fix has been checked in.
Status: NEW → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Whiteboard: nsbeta3+ → nsbeta3+, fix checked in
Shanjian, you seemed to check in your original.
I'm fine if you have checked mine and then decide to
use yours. But just for sure.
toshi, I didn't noticed your comment when I did the check in. Since it does not 
make much difference, I will stick to mine. I am still working on on-the-spot
problem. If that can be resolve, those fix will be backed out. Otherwise, I may 
try the combination as you suggested and finalize it after PR3.
shanjian, no problem.

Verified.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: