]> git.ipfire.org Git - thirdparty/snapper.git/commitdiff
Report the proper path
authorGergo Borus <41896618+gergo-b@users.noreply.github.com>
Tue, 20 Nov 2018 20:56:32 +0000 (21:56 +0100)
committerGergo Borus <41896618+gergo-b@users.noreply.github.com>
Tue, 20 Nov 2018 20:56:32 +0000 (21:56 +0100)
snapper/FileUtils.cc

index e607c15169be272817b627fdc7b7de45329ac48d..364dd590d49518f461a7a14e3b2a0434c05f6e01 100644 (file)
@@ -84,8 +84,11 @@ namespace snapper
 
        dirfd = ::openat(dir.dirfd, name.c_str(), O_RDONLY | O_NOFOLLOW | O_NOATIME | O_CLOEXEC);
        if (dirfd < 0)
-           SN_THROW(IOErrorException(sformat("open failed path:%s errno:%d (%s)", dir.fullname().c_str(),
+       {
+           string failed_path = dir.fullname() + "/" + name;
+           SN_THROW(IOErrorException(sformat("open failed path:%s errno:%d (%s)", failed_path.c_str(),
                                              errno, stringerror(errno).c_str())));
+       }
 
        struct stat buf;
        if (fstat(dirfd, &buf) != 0)