check datasource in envelope method
This commit is contained in:
parent
7f4df91371
commit
aaba4d08cf
1 changed files with 3 additions and 1 deletions
|
@ -162,7 +162,9 @@ namespace mapnik
|
|||
|
||||
const Envelope<double>& Layer::envelope() const
|
||||
{
|
||||
return ds_->envelope();
|
||||
if (ds_)
|
||||
return ds_->envelope();
|
||||
return Envelope<double>();
|
||||
}
|
||||
|
||||
void Layer::selection_style(const std::string& name)
|
||||
|
|
Loading…
Add table
Reference in a new issue