Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java Machine > Re: modifying j...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 9 Topic 764 of 816
Post > Topic >>

Re: modifying java.lang.String.java

by "Ralf Ullrich" <news@[EMAIL PROTECTED] > Mar 26, 2007 at 01:21 AM

danwichs@[EMAIL PROTECTED]
 wrote:

>On Mar 25, 7:06 pm, "Ralf Ullrich" <n...@[EMAIL PROTECTED]
> wrote:
>>danwi...@[EMAIL PROTECTED]
 wrote:
>>>  I'm trying to modify java.lang.String.java and add the modified
>>>String.class to
>>>rt.jar [THIS IS FOR MYSELF ONLY AND WILL NOT BE DEPLOYED].
>>
>>Try running the VM with
>
>>    -Xshare:off
>>
>>If this works re-create the shared archives
>>(JAVA_HOME/bin/(client|server)/cl*****.jsa).
>>
>>HTH
>>
>>cu
>
>That still does not work. I get the same error.

Well, the offending code seems to be this line in java.lang.Thread:

   private static final RuntimePermission
       SUBCLASS_IMPLEMENTATION_PERMISSION =
           new RuntimePermission("enableContextClassLoaderOverride");

where "new RuntimePermission(...)" results in your observed error if the 
supplied string returns 0 for length().

So I would assume, that after you modified java.lang.String the magic 
trickery within the VM that creates String objects from String literals in

class files is broken with regard to your modified String class.

I'd try to look there for the problem.

Sorry, that I cannot be of more help.

cu
 




 9 Posts in Topic:
modifying java.lang.String.java
"danwichs@[EMAIL PRO  2007-03-25 15:00:27 
Re: modifying java.lang.String.java
"Ralf Ullrich"   2007-03-25 23:06:17 
Re: modifying java.lang.String.java
"danwichs@[EMAIL PRO  2007-03-25 17:58:40 
Re: modifying java.lang.String.java
"Ralf Ullrich"   2007-03-26 01:21:15 
Re: modifying java.lang.String.java
"danwichs@[EMAIL PRO  2007-03-25 18:34:14 
Re: modifying java.lang.String.java
"danwichs@[EMAIL PRO  2007-03-25 19:10:28 
Re: modifying java.lang.String.java
Tom Hawtin <usenet@[EM  2007-03-26 09:30:37 
Re: modifying java.lang.String.java
Moritz Hammer <newsgro  2007-03-26 11:43:56 
Re: modifying java.lang.String.java
"danwichs@[EMAIL PRO  2007-03-26 06:49:45 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Jul 26 5:04:50 CDT 2008.