From: František Dvořák Date: Thu, 17 Oct 2013 17:48:00 +0000 (+0200) Subject: More friendly error message for makeDir(""). X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=fc3f1ba3c098d7bb4597ad4427d307fef44a9c62;p=dmlite-plugins-vfs.git More friendly error message for makeDir(""). --- diff --git a/src/VfsNs.cpp b/src/VfsNs.cpp index 26793dd..c7c6b92 100644 --- a/src/VfsNs.cpp +++ b/src/VfsNs.cpp @@ -673,6 +673,9 @@ void VfsCatalog::makeDir(const std::string& path, mode_t mode) throw (DmExceptio { std::string parentPath, name; + if (path.empty()) + vfsThrow(EINVAL, "empty directory name"); + ExtendedStat parent = this->getParent(path, &parentPath, &name); if (checkPermissions(this->secCtx_, parent.acl, parent.stat, S_IEXEC) != 0)