You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2007/03/05 18:15:14 UTC

DO NOT REPLY [Bug 41766] New: - apache-tomcat-5.5.20-src.tar.gz includes broken class files

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41766>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41766

           Summary: apache-tomcat-5.5.20-src.tar.gz includes broken class
                    files
           Product: Tomcat 5
           Version: 5.5.20
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Unknown
        AssignedTo: tomcat-dev@jakarta.apache.org
        ReportedBy: andrew.benham@thus.net


If one downloads and unpacks apache-tomcat-5.5.20-src.tar.gz, one can observe
that some of the .class files in it are broken.

For example:

$ /usr/java/jdk1.5/bin/java -classpath
./connectors/jk/jkstatus/build/classes/org/apache/jk/status JkServer

Exception in thread "main" java.lang.ClassFormatError: Unknown constant tag 97
in class file JkServer
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
        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:306)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)


When we rebuild tomcat ourselves, our resultant .class files are OK.

When we compare your original and our .class files, we observe that the
differences are that where you have 0x0a bytes, we have 0x0d bytes.

E.g. if we hex dump
./connectors/jk/jkstatus/build/classes/org/apache/jk/status/JkServer.class,
your file reads:

                        VV  
0000160: 4669 6c65 0100 0a4a 6b53 6572 7665 722e  File...JkServer.
0000170: 6a61 7661 0c00 0e00 0f0c 0009 000a 0c00  java............

whereas our is:
                        VV 
0000160: 4669 6c65 0100 0d4a 6b53 6572 7665 722e  File...JkServer.
0000170: 6a61 7661 0c00 0e00 0f0c 0009 000a 0c00  java............

The length of the string 'JkServer.java' is 13 chars (0x0d), and not
the 10 chars (0x0a) which your length byte tells us.


Looks to me like you're got an erroneous end-of-line character translation
happening, perhaps in your source code versioning system.

We now delete all your .class files because they are suspect.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 41766] - apache-tomcat-5.5.20-src.tar.gz includes broken class files

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41766>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41766


markt@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |RESOLVED
         Resolution|                            |FIXED




------- Additional Comments From markt@apache.org  2007-06-14 17:33 -------
I have amended the build script to prevent this. The fix will apply to 5.5.25
onwards.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 41766] - apache-tomcat-5.5.20-src.tar.gz includes broken class files

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41766>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41766





------- Additional Comments From andrew.benham@thus.net  2007-03-26 05:30 -------
(In reply to comment #3)
> And 6.0.10, for that matter?

(In reply to comment #2)
> Andrew, is the behavior the same for 5.5.23?

Exactly the same behaviour in 5.5.23, for example:

/tmp/apache-tomcat-5.5.23-src/connectors/jk/jkstatus/build/classes/org/apache/jk/status$
/usr/java/jdk1.5/bin/javap JkStatus
java.lang.ClassFormatError: invalid constant type: 97
        at sun.tools.javap.ClassData.readCP(ClassData.java:180)
        at sun.tools.javap.ClassData.read(ClassData.java:81)
        at sun.tools.javap.ClassData.<init>(ClassData.java:52)
        at sun.tools.javap.JavapPrinter.<init>(JavapPrinter.java:28)
        at sun.tools.javap.Main.displayResults(Main.java:201)
        at sun.tools.javap.Main.perform(Main.java:61)
        at sun.tools.javap.Main.entry(Main.java:49)
        at sun.tools.javap.Main.main(Main.java:34)
ERROR:fatal error
Exception in thread "main" java.lang.NullPointerException
        at sun.tools.javap.JavapPrinter.javaclassname(JavapPrinter.java:791)
        at sun.tools.javap.JavapPrinter.printclassHeader(JavapPrinter.java:60)
        at sun.tools.javap.JavapPrinter.print(JavapPrinter.java:36)
        at sun.tools.javap.Main.displayResults(Main.java:202)
        at sun.tools.javap.Main.perform(Main.java:61)
        at sun.tools.javap.Main.entry(Main.java:49)
        at sun.tools.javap.Main.main(Main.java:34) 



Problem isn't present in 6.0.10, simply because there are no class files in the
tarball.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 41766] - apache-tomcat-5.5.20-src.tar.gz includes broken class files

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41766>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41766





------- Additional Comments From andrew.benham@thus.net  2007-03-05 09:36 -------
Or perhaps you did not mean to include the directories:

./connectors/jk/jkstatus/build

and 

./connectors/jk/jkstatus/dist

in the tarball ??

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 41766] - apache-tomcat-5.5.20-src.tar.gz includes broken class files

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41766>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41766


yoavs@computer.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO




------- Additional Comments From yoavs@computer.org  2007-03-25 15:49 -------
Andrew, is the behavior the same for 5.5.23?

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 41766] - apache-tomcat-5.5.20-src.tar.gz includes broken class files

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41766>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41766





------- Additional Comments From yoavs@computer.org  2007-03-25 15:50 -------
And 6.0.10, for that matter?

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org