ForceToRelativePath: Fix spurious assertion when local path is root dir

Fixes: #19909
47 jobs for root-dir-assertion-fix
Status Name Job ID Coverage
  External
passed cdash

passed cmake-dash3win10-windows-release-ninja

passed cmake-hythloth-linux-debug-makefiles+sphinx

passed cmake-minoc-linux-release-lint-iwyu-tidy

passed cmake-moonshade-osx-debug-ninja

passed cmake-moonshade-osx-release-makefiles

passed cmake-terfin-windows-release-vs2019

passed ghostflow-check-master

passed ghostflow-stager

passed cmake-dash3win10-windows-release-ninja

passed cmake-dash3win10-windows-release-ninja

00:20:30

passed cmake-hythloth-linux-debug-makefiles+sphinx

passed cmake-hythloth-linux-debug-makefiles+sphinx

00:51:49

passed cmake-minoc-linux-release-lint-iwyu-tidy

passed cmake-minoc-linux-release-lint-iwyu-tidy

00:14:08

passed cmake-moonshade-osx-debug-ninja

passed cmake-moonshade-osx-debug-ninja

00:15:31

passed cmake-moonshade-osx-release-makefiles

passed cmake-moonshade-osx-release-makefiles

00:12:58

passed cmake-terfin-windows-release-vs2019

passed cmake-terfin-windows-release-vs2019

00:37:10

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager