I guess the decompiler did not do a good job. You will have to spend more time with the source to create a good version.
Can you contact the author of the program and get a clean copy of the source...