#3 Invalid start_pc/length in local var table

closed-fixed
Neville Kadwa
5
2003-03-06
2003-03-05
Jeff Drost
No

[warn ] main 03.05 11:49:52.914 - main
([Ljava/lang/String;)V - threw java.lang.ClassFormatError
java.lang.ClassFormatError: weblogic/t3/srvr/T3Srvr
(Invalid start_pc/length in local var table)
at java.lang.ClassLoader.defineClass0(Native
Method)
at java.lang.ClassLoader.defineClass
(ClassLoader.java:486)
at java.security.SecureClassLoader.defineClass
(SecureClassLoader.java:111)
at java.net.URLClassLoader.defineClass
(URLClassLoader.java:248)
at java.net.URLClassLoader.access$100
(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run
(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged
(Native Method)
at java.net.URLClassLoader.findClass
(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass
(ClassLoader.java:297)
at sun.misc.Launcher$AppClassLoader.loadClass
(Launcher.java:286)
at java.lang.ClassLoader.loadClass
(ClassLoader.java:253)
at java.lang.ClassLoader.loadClassInternal
(ClassLoader.java:313)
at weblogic.Server.__shiftone_JRAT_main
(Server.java:35)
at weblogic.Server.main(Server.java)
[info ] main 03.05 11:49:52.924 - main([Ljava/lang/String;)
V - failed in 10ms

Discussion

  • Jeff Drost
    Jeff Drost
    2003-03-05

     
    Attachments
  • Jeff Drost
    Jeff Drost
    2003-03-05

     
    Attachments
  • Jeff Drost
    Jeff Drost
    2003-03-05

     
    Attachments
  • Neville Kadwa
    Neville Kadwa
    2003-03-05

    Logged In: YES
    user_id=382387

    problem is that an anonymous inner class got a static
    member variable inserted.

    from
    http://java.sun.com/docs/books/tutorial/java/javaOO/nested.ht
    ml:
    As with instance methods and variables, an inner class is
    associated with an instance of its enclosing class and has
    direct access to that object's instance variables and
    methods. Also, because an inner class is associated with an
    instance, it cannot define any static members itself.

    Suggested solution:
    detect non-static inner classes and place their method
    handlers in the parent class...

     
  • Neville Kadwa
    Neville Kadwa
    2003-03-05

    • assigned_to: nobody --> pandama
     
  • Jeff Drost
    Jeff Drost
    2003-03-06

    Logged In: YES
    user_id=348597

    Ignoring classes with "$" in their name does not fix the
    problem. The issue is in the outer class, not the inner.

    Same problem found with...
    java.lang.ClassFormatError: weblogic/common/ParamSet
    (Invalid start_pc/length in local var table)

     
  • Jeff Drost
    Jeff Drost
    2003-03-06

    Logged In: YES
    user_id=348597

    correction : weblogic/common/ParamSet does not appear to
    have inner classes.

    Others that may have the same issue
    weblogic/t3/srvr/ListenThread does
    weblogic/t3/srvr/SSLListenThread ?
    weblogic/event/server/EventMessage
    weblogic/t3/srvr/T3SrvrConsole
    weblogic/security/internal/ServerAuthenticate
    weblogic/utils/classloaders/ClasspathClassFinder
    weblogic/utils/StringUtils
    weblogic/kernel/ExecuteThreadManager

     
  • Neville Kadwa
    Neville Kadwa
    2003-03-06

    Logged In: YES
    user_id=382387

    found the cause to be the end instruction on local variables in
    cases where the original method is larger than the generated
    replacement...

     
  • Neville Kadwa
    Neville Kadwa
    2003-03-06

    • status: open --> closed-fixed
     
  • Jeff Drost
    Jeff Drost
    2003-03-08

    Logged In: YES
    user_id=348597

    Actually, the problem was the the "real" method is copied to
    create the proxy method. Any existing local variables that
    the "real" method had got their scopes messed up by the fact
    that the instructions are replaced. The solution is to remove
    existing local valiebles in the proxy method.

    methodGen.removeLocalVariables();