Index: media/filters/chunk_demuxer.h |
diff --git a/media/filters/chunk_demuxer.h b/media/filters/chunk_demuxer.h |
index b39e7af2cee0bc06bef426766d5cbb75858cb54a..42b714ed46c35ad60abff868da891ac007185920 100644 |
--- a/media/filters/chunk_demuxer.h |
+++ b/media/filters/chunk_demuxer.h |
@@ -41,7 +41,11 @@ class ChunkDemuxer : public Demuxer { |
// Methods used by an external object to control this demuxer. |
void FlushData(); |
+ |
+ // Appends media data to the stream. Returns false if this method |
+ // is called in an invalid state. |
bool AppendData(const uint8* data, unsigned length); |
+ |
void EndOfStream(PipelineStatus status); |
bool HasEnded(); |
void Shutdown(); |
@@ -52,7 +56,7 @@ class ChunkDemuxer : public Demuxer { |
INITIALIZING, |
INITIALIZED, |
ENDED, |
- INIT_ERROR, |
+ PARSE_ERROR, |
SHUTDOWN, |
}; |
@@ -76,8 +80,12 @@ class ChunkDemuxer : public Demuxer { |
// contain one or more WebM Clusters. Returns false if parsing the data fails. |
bool ParseAndAppendData_Locked(const uint8* data, int length); |
- // Called when initialization fails. Handles calling & clearing init_cb_. |
- void InitFailed_Locked(); |
+ // Schedules a ReportErrorTask() call to report error status to the pipeline. |
+ void ReportError_Locked(PipelineStatus status); |
+ |
+ // Reports an error and puts the demuxer in a state where it won't accept more |
+ // data. |
+ void ReportErrorTask(PipelineStatus status); |
base::Lock lock_; |
State state_; |