Bump patch version post tag.
[asdcplib.git] / src / MPEG2_Parser.cpp
index 62eb5f58265e153adecc23e51831de6143b8ea66..89abbfd30a790cdcdc498fc30990b6829b0bd551 100755 (executable)
@@ -1,5 +1,5 @@
 /*
-Copyright (c) 2004-2009, John Hurst
+Copyright (c) 2004-2011, John Hurst
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
@@ -368,10 +368,10 @@ class ASDCP::MPEG2::Parser::h__Parser
   ASDCP_NO_COPY_CONSTRUCT(h__Parser);
 
 public:
-  h__Parser() : m_TmpBuffer(VESReadSize*2) {}
+  h__Parser() : m_TmpBuffer(VESReadSize*8) {}
   ~h__Parser() { Close(); }
 
-  Result_t OpenRead(const char* filename);
+  Result_t OpenRead(const std::string& filename);
   void     Close();
   Result_t Reset();
   Result_t ReadFrame(FrameBuffer&);
@@ -399,9 +399,8 @@ ASDCP::MPEG2::Parser::h__Parser::Close()
 
 //
 ASDCP::Result_t
-ASDCP::MPEG2::Parser::h__Parser::OpenRead(const char* filename)
+ASDCP::MPEG2::Parser::h__Parser::OpenRead(const std::string& filename)
 {
-  ASDCP_TEST_NULL_STR(filename)
   ui32_t read_count = 0;
 
   Result_t result = m_FileReader.OpenRead(filename);
@@ -443,7 +442,7 @@ ASDCP::MPEG2::Parser::h__Parser::OpenRead(const char* filename)
 
   if ( ASDCP_FAILURE(result) )
     {
-      DefaultLogSink().Error("Unable to identify a wrapping mode for the essence in file \"%s\"\n", filename);
+      DefaultLogSink().Error("Unable to identify a wrapping mode for the essence in file \"%s\"\n", filename.c_str());
       m_FileReader.Close();
     }
 
@@ -566,7 +565,7 @@ ASDCP::MPEG2::Parser::~Parser()
 // Opens the stream for reading, parses enough data to provide a complete
 // set of stream metadata for the MXFWriter below.
 ASDCP::Result_t
-ASDCP::MPEG2::Parser::OpenRead(const char* filename) const
+ASDCP::MPEG2::Parser::OpenRead(const std::string& filename) const
 {
   const_cast<ASDCP::MPEG2::Parser*>(this)->m_Parser = new h__Parser;