Potential fix for #588.

This commit is contained in:
Robin Sommer 2011-09-07 11:03:36 -07:00
parent eda2245e9e
commit f868af101c
3 changed files with 18 additions and 3 deletions

View file

@ -444,7 +444,7 @@ LogMgr::WriterInfo* LogMgr::FindWriter(LogWriter* writer)
{
WriterInfo* winfo = i->second;
if ( winfo->writer == writer )
if ( winfo && winfo->writer == writer )
return winfo;
}
}
@ -1506,7 +1506,8 @@ bool LogMgr::FinishedRotation(LogWriter* writer, string new_name, string old_nam
writer->Path().c_str(), network_time, new_name.c_str());
WriterInfo* winfo = FindWriter(writer);
assert(winfo);
if ( ! winfo )
return true;
RecordVal* rc =
LookupRotationControl(winfo->type, winfo->writer->Path());