From 568a099c889e7ccc5a49b15575078e99acf8bc2f Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 13 Apr 2017 15:32:43 +0200 Subject: canonPath(): Check against empty paths --- src/libutil/util.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/libutil/util.cc b/src/libutil/util.cc index a640a64c7..0bd51afd1 100644 --- a/src/libutil/util.cc +++ b/src/libutil/util.cc @@ -96,6 +96,8 @@ Path absPath(Path path, Path dir) Path canonPath(const Path & path, bool resolveSymlinks) { + assert(path != ""); + string s; if (path[0] != '/') -- cgit v1.2.3