Closed Bug 363822 Opened 18 years ago Closed 18 years ago

Bus Error in Java VM (/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Libraries/libclient.dylib at address "jio_snprintf + 412340").

Categories

(Core Graveyard :: Java: OJI, defect)

1.8 Branch
PowerPC
macOS
defect
Not set
critical

Tracking

(Not tracked)

VERIFIED WORKSFORME

People

(Reporter: ralph, Assigned: yuanyi21)

References

()

Details

(Keywords: crash)

Attachments

(6 files)

User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.0.7) Gecko/20060911 Camino/1.0.3
Build Identifier: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.0.7) Gecko/20060911 Camino/1.0.3

Attempting to navigate to the URL specified above caused Camino to terminate on a Bus Error.  Same behaviour observed with "Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1) Gecko/20061010 Firefox/2.0".

Reproducible: Always

Steps to Reproduce:
1. Navigate to www.ttc.ca.
2. Observe browser magically disappear.

Actual Results:  
Browser terminates abnormally on bus error.

Expected Results:  
A valid address.

Will attach Camino and Firefox crash log files and Java VM log files.
The 3 bus errors described in this file correspond to the following 3 Java Native Crash log files:
   JavaNativeCrash_pid262.crash.log
   JavaNativeCrash_pid429.crash.log
   JavaNativeCrash_pid431.crash.log
Corresponds to first bus error described in file Camino.crash.log.
Attachment #248639 - Attachment description: Log file describing 3 instances of the same bus error. → Log file describing 3 instances of the same bus error in Camino.
Keywords: crash
Attachment #248640 - Attachment description: Log file describing bus error in Java VM. → Log file describing bus error in Java VM executing within Camino.
Attachment #248639 - Attachment description: Log file describing 3 instances of the same bus error in Camino. → Log file Camino.crash.log describing 3 instances of the same bus error.
Attachment #248640 - Attachment description: Log file describing bus error in Java VM executing within Camino. → Log file JavaNativeCrash_pid262.crash.log describing bus error in Java VM within Camino.
Corresponds to second bus error described in file Camino.crash.log.
Corresponds to third bus error described in file Camino.crash.log.
Corresponds to the Java Native Crash log file JavaNativeCrash_pid454.crash.log.
Corresponds to bus error described in file firefox-bin.crash.log.
what version of JEP do you have?
Assignee: nobody → yuanyi21
Component: Plug-ins → Java: OJI
Product: Camino → Core
QA Contact: plugins → zhayupeng
Version: unspecified → 1.8 Branch
I'm not able to reproduce this problem.  I tested with Camino 1.0.3
and Firefox 2.0 on a MacBook Pro (i.e. an Intel Mac) -- which is what
I assume you (Ralph) have.

My hunch is that the difference between your machine and mine is that,
though you have the latest version (10.4.8) of Mac OS X, you don't yet
have Apple's latest Java release (J2SE 5.0 Release 4).  Try
downloading the Intel version of this from
http://developer.apple.com/java/download/ and installing it.  Let us
know your results.

> what version of JEP do you have?

This information is actually available in the crashreporterd crash
logs -- Ralph is using the bundled JEP versions (0.9.5+g with Camino
1.0.3 and 0.9.5+g+2 with Firefox 2.0).

By the way, Ralph, thanks very much for including all those logs.
They do (as you'd expect) include a lot of extraneous information
... but it's always better to have too much of this kind of
information than not enough.  If my hunch is right (if upgrading to
J2SE 5.0 Release 4 resolves your problem), the crucial piece of
information will have been the calls to
jep.AppletHolderFactory.callRegisterNatives() in the "Java native"
crash logs (more about this later).
> My hunch is that the difference between your machine and mine is that,
> though you have the latest version (10.4.8) of Mac OS X, you don't yet
> have Apple's latest Java release (J2SE 5.0 Release 4).  Try
> downloading the Intel version of this from
> http://developer.apple.com/java/download/ and installing it.

It appears that you might be right.  Java 2 Standard Edition (J2SE) 5.0 Release 4 apparently includes J2SE version 1.5.0_06 while I am currently using version 1.4.2_09, as is shown by the following:

[Ralphs-Laptop:~] ralph% java -version
java version "1.4.2_09"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_09-239)
Java HotSpot(TM) Client VM (build 1.4.2-66, mixed mode)
[Ralphs-Laptop:~] ralph% 

I will install the new Java release and report back.
> I will install the new Java release and report back.

I've installed J2SE 5.0 Release 4 and I am happy to report that it resolved the problem. :)

Thanks Steven for your help.
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Status: RESOLVED → UNCONFIRMED
Resolution: FIXED → ---
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago18 years ago
Resolution: --- → WORKSFORME
Status: RESOLVED → VERIFIED
> Thanks Steven for your help.

You're most welcome.

You've already resolved this problem by upgrading to Apple's J2SE 5.0
Release 4.  But (just for the record), I've now released a new version
(0.9.6) of the Java Embedding Plugin that would have worked properly
even with your old Java release (the one that came installed on your
MacBook Pro).  See bug 364158.

The problem was that your original Java release (probably the rough
equivalent of J2SE 5.0 Release 3 for PPC Macs) had different version
information than its PPC equivalent -- in fact the
CFBundleShortVersionString (of JavaPluginCocoa.bundle) was the same
for Java 1.4.2 and Java 5.0!  JEP 0.9.6 now knows where else to look
for the Intel J2SE 5.0 Release 3's version information.  But earlier
versions of the JEP always assumed that users of J2SE 5.0 Release 3 on
Intel Macs had chosen Java 5.0.  This was fine if you'd actually
chosen to use Java 5.0.  But if you were using Apple's default setting
of Java 1.4.2, or if you'd explicitly chosen Java 1.4.2, recent JEP
versions (JEP 0.9.5+f, 0.9.5+g and 0.9.5+g+2) would crash.  (Earlier
JEP versions just always used Java 5.0.)

The crashes I've seen have always been in AppletView.m's
Java_callRegisterNatives(), which is called from
AppletHolderFactory.callRegisterNatives() (name changed to
AppletHandlerFactory.callRegisterNatives() in JEP 0.9.6).
registerNatives() is actually an undocumented Apple method, used to
connect up the JVM's JNI underpinnings (what it uses to call Cocoa
code).  It works fine if both the JEP and Apple's code agree which
Java version is being used.  But crashes result if there's a
disagreement.

(Yes, Apple uses confusing names for its Java "releases".  Both "J2SE
5.0 Release 3" and 'J2SE 5.0 Release 4" allow you to choose either
Java 1.4.2 or Java 5.0.  "Release 3" defaulted to Java 1.4.2.
"Release 4" defaults to Java 5.0.  "Release 4" also has proper
versioning information -- i.e. there's a reasonable (though still
undocumented) way to find out which Java version the user has chosen.)
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: