BaseImporter: Remove dead condition
operator new never returns NULL, it throws exception on allocation failurepull/1765/head
parent
be865ae613
commit
da19ed0b2a
|
@ -157,9 +157,6 @@ void BaseImporter::GetExtensionList(std::set<std::string>& extensions)
|
||||||
// read 200 characters from the file
|
// read 200 characters from the file
|
||||||
std::unique_ptr<char[]> _buffer (new char[searchBytes+1 /* for the '\0' */]);
|
std::unique_ptr<char[]> _buffer (new char[searchBytes+1 /* for the '\0' */]);
|
||||||
char* buffer = _buffer.get();
|
char* buffer = _buffer.get();
|
||||||
if( NULL == buffer ) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
const size_t read = pStream->Read(buffer,1,searchBytes);
|
const size_t read = pStream->Read(buffer,1,searchBytes);
|
||||||
if( !read ) {
|
if( !read ) {
|
||||||
|
|
Loading…
Reference in New Issue