On Mac OSX 10.7.5, using CvCapture, when the end of the video is reached, the video is looped back to the beginning instead of returning NULL. This has also been reported here and here.
Using the frame-count work around is problematic for cases that have to support both endless streaming video and video files.
Does anyone know how to fix this problem?