fixed Java/C# issues