forked from organicmaps/organicmaps
Cross section generation crash fix
This commit is contained in:
parent
d730b89b55
commit
9f859f252c
1 changed files with 0 additions and 13 deletions
|
@ -176,23 +176,10 @@ void WriteCrossSection(routing::CrossRoutingContextWriter const & crossContext,
|
|||
|
||||
FilesContainerW routingCont(fPath, FileWriter::OP_WRITE_EXISTING);
|
||||
|
||||
{
|
||||
// Write version for routing file that is equal to correspondent mwm file.
|
||||
FilesContainerR mwmCont(mwmFile);
|
||||
|
||||
FileWriter w = routingCont.GetWriter(VERSION_FILE_TAG);
|
||||
ReaderSource<ModelReaderPtr> src(mwmCont.GetReader(VERSION_FILE_TAG));
|
||||
rw::ReadAndWrite(src, w);
|
||||
w.WritePaddingByEnd(4);
|
||||
}
|
||||
|
||||
FileWriter w = routingCont.GetWriter(ROUTING_CROSS_CONTEXT_TAG);
|
||||
size_t const start_size = w.Pos();
|
||||
crossContext.Save(w);
|
||||
w.WritePaddingByEnd(4);
|
||||
LOG(LINFO, ("Have written routing info, bytes written:", w.Pos() - start_size, "bytes"));
|
||||
|
||||
routingCont.Finish();
|
||||
}
|
||||
|
||||
void BuildCrossRoutingIndex(string const & baseDir, string const & countryName, string const & osrmFile)
|
||||
|
|
Loading…
Add table
Reference in a new issue