Skip to content
Snippets Groups Projects

SystemTools: Refactor CollapseFullPath to call getcwd only when needed

Many calls to the one-argument CollapseFullPath variant already have an absolute path and just need to collapse it. Avoid calling getcwd if the result is not needed because it can be an expensive syscall.

Also drop the GetCurrentWorkingDirectory argument and never call CollapseFullPath inside it. The result of getcwd is always an absolute canonical path and does not need to be collapsed.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading