Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • otb otb
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 204
    • Issues 204
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 11
    • Merge requests 11
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Main Repositories
  • otbotb
  • Merge requests
  • !917

Avoid reloading the same DEM directory

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Julien Osman requested to merge dem-big-folder into develop Jun 13, 2022
  • Overview 3
  • Commits 4
  • Pipelines 4
  • Changes 2

Summary

Avoid reloading the same DEM directory.

Fix segfault when a corrupted simlink is present in the DEM directory.

Rationale

To set the directory containing the DEM in the DEMHandler, one calls DEMHandler::OpenDEMDirectory. Due to how the Application framework works, with the DoUpdateParameters function being called for each parameter, the same directory may be set multiple times, unloading and loading the same data each time. To avoid this, we propose to modify the DEMHandler so it doesn't reload a directory if one calls DEMHandler::OpenDEMDirectory with the same path.

Also, when there is a simlink in the DEM directory, if this simlink links to itself, it makes OTB exit with a segfault. We propose to handle this case correctly by ignoring this simlink.

Implementation Details

Classes and files
  • Modules/IO/IOGDAL/src/otbDEMHandler.cxx

Copyright

The copyright owner is CNES and has signed the ORFEO ToolBox Contributor License Agreement.


Check before merging:

  • All discussions are resolved
  • At least 2 👍 votes from core developers, no 👎 vote.
  • The feature branch is (reasonably) up-to-date with the base branch
  • Dashboard is green
  • Copyright owner has signed the ORFEO ToolBox Contributor License Agreement
  • Optionally, run git diff develop... -U0 --no-color | clang-format-diff.py -p1 -i on latest changes and commit
Edited Jun 13, 2022 by Julien Osman
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: dem-big-folder