setTimeOut crashes Flash player
December 2nd, 2008
No comments
I just spent the best part of the morning fixing a bug in a website that made my browser crash when I was trying to play a video in Flash using the FLVPlayback component.
What turned out to be the problem? Well, it was the fact that we used the built-in setTimeOut method to keep checking the buffering progress of the video. It would crash Flash player without exception. I removed the call to this method and replaced it by an enter frame listener, and now it works like a charm. No more crashing.
I haven’t tested it thoroughly yet, but it seemed to appear after I had upgraded to Flash CS4, making Flash Player 10 a suspicious candidate. So my suggestion is: avoid this utility method where possible!
Categories: programming