"You are allowed to edit the game in any way, providing you do not edit it in such a way that it is either intentionally damaging to people's PCs, or removes the login system and enables people to play the game without purchasing." - From rules of modding in this section of forum. So I think you are allowed to release your fix even if it modifies java files.