* Martin Scheffler <the_bishop at web.de> [2006-09-10 07:02:26]: > i have the following problem with compiling the source with gcj, > how do i convert the byte array into a int array in the easiest way? > i looked around the net and did not find any clue. how does the sun-jvm > handle this? > > this is the output from the compiler: > > src/freenet/client/StandardOnionFECCodec.java: In > class 'freenet.client.StandardOnionFECCodec': > src/freenet/client/StandardOnionFECCodec.java: In > method > 'freenet.client.StandardOnionFECCodec.pad(freenet.support.io.Bucket,int,freenet.support.io.BucketFactory,int)': > src/freenet/client/StandardOnionFECCodec.java:501: error: Can't find > constructor 'org.spaceroots.mantissa.random.MersenneTwister([B)' in > type 'org.spaceroots.mantissa.random.MersenneTwister'. > MersenneTwister mt = new MersenneTwister(hash); > ^ > 1 error > -------------------------------------------------------------------------- > src/freenet/keys/ClientCHKBlock.java: In > class 'freenet.keys.ClientCHKBlock': > src/freenet/keys/ClientCHKBlock.java: In > method > 'freenet.keys.ClientCHKBlock.encode(freenet.support.io.Bucket,boolean,boolean,short,long)': > src/freenet/keys/ClientCHKBlock.java:153: error: Can't find > constructor 'org.spaceroots.mantissa.random.MersenneTwister([B)' in > type 'org.spaceroots.mantissa.random.MersenneTwister'. > MersenneTwister mt = new MersenneTwister(digest); > ^
I don't get what the problem is : I've never experienced it myself and I see in https://emu.freenetproject.org/svn/trunk/freenet/src/org/spaceroots/mantissa/random/MersenneTwister.java /** Seed from byte[] */ public MersenneTwister(byte[] seed) { mt = new int[N]; setSeed(seed); } So you don't have to cast to int[]. -- NextGen$. ---> In a world without fences nor walls - who needs windows and gates ? On peut ob??r aux lois en souhaitant qu'elles changent, comme on sert ? la guerre en souhaitant la paix. Merleau Ponty "L'?loge de la philosophie" -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: Digital signature URL: <https://emu.freenetproject.org/pipermail/devl/attachments/20060911/622c463f/attachment.pgp>
