In our Java project, I had some frustrating errors that I can't figure out till now.
The project is video streaming and I am using JMF.
I tried to send frame by frame at first. The client only displayed the first frame and stopped althought the server is showing the video correctly. I discovered after five days of tracing and testing the BufferedImage and ObjectStream and BufferToImage, that the problem was solved when I reallocated the byte array every time instead of reusing it!
Another one, using the RTPManager of JMF, both the server and the client was on the same machine, the program never worked when using 127.0.0.1, I had to use the actual IP of my machine (I wonder what if I was disconnect and don't have an IP ?)
Today I had a strange error too, I still didn't trace it. I initialize ActionEvent(this,0,"GotPlayer"), I get an exception telling me the the source (this) is null. I tried to ActionEvent(new Object(),0,"GotPlayer"), I got the same error too!
Please somebody have an answer tell me, I really got tired of that.
Ah, by the way, sometime we got an error in our MFC project, a line that assigns a function to a function pointer, we traced it, the funtion pointer is still = null after the assignment although the watch of the function itself (the right hand side of the assignment) was not null.
Either, the evil forces of darkness has conspired upon us, or this is really some programming myths that should be reserved for history cuz maybe after 1000 years the sercret will be unvield!