Fix #4212
This commit is contained in:
parent
6b328c2698
commit
41d7333300
1 changed files with 2 additions and 1 deletions
|
@ -288,8 +288,8 @@ public class AppInitializer implements IProgress {
|
|||
}
|
||||
|
||||
private void indexRegionsBoundaries(List<String> warnings) {
|
||||
File file = app.getAppPath("regions.ocbf");
|
||||
try {
|
||||
File file = app.getAppPath("regions.ocbf");
|
||||
if (file != null) {
|
||||
if (!file.exists()) {
|
||||
Algorithms.streamCopy(OsmandRegions.class.getResourceAsStream("regions.ocbf"),
|
||||
|
@ -300,6 +300,7 @@ public class AppInitializer implements IProgress {
|
|||
}
|
||||
} catch (Exception e) {
|
||||
warnings.add(e.getMessage());
|
||||
file.delete(); // recreate file
|
||||
LOG.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue