ui/ncurses: Fix adding unnecessary leading slashes to paths