GNOME Bugzilla – Bug 142903
[PATCH] fdsrc element never resets buffer offset to zero
Last modified: 2004-12-22 21:47:04 UTC
The fdsrc element will always increment its buffer offset after being created, and will never reset this offset to zero. This poses a problem, for example, with spider, which requires the offset to be zero for type detection to occur. This pipeline: fdsrc ! spider ! osssink Will work the first time it is used -- but if spider is removed and replaced with a new spider for detecting a new audio file, the type detection will fail.
Created attachment 27906 [details] [review] Patch to fix issue This patch resets the buffer offset to zero during the READY_TO_PAUSED transition. I chose this behavior because it roughly duplicates the functionality of the filesrc element, which opens a the file during the READY_TO_PAUSED transition. This seemed like the best solution to me, although another option would be to reset the offset whenever the filedescriptor of the fdsrc is set.
applied