Lines Matching refs:localPath
265 context->localPath.c_str(), context->openFd);
347 context->localPath.c_str(), thisClass->taskInfo->channelId, req->result);
354 context->localPath.c_str());
355 WRITE_LOG(LOG_FATAL, "open path:%s error:%s", context->localPath.c_str(), buf);
383 getfilecon(context->localPath.c_str(), &con);
395 uv_fs_chmod(nullptr, &fs, context->localPath.c_str(), mode.perm, nullptr);
396 uv_fs_chown(nullptr, &fs, context->localPath.c_str(), mode.uId, mode.gId, nullptr);
402 setfilecon(context->localPath.c_str(), mode.context.c_str());
527 bool HdcTransferBase::CheckLocalPath(string &localPath, string &optName, string &errStr)
529 // If optName show this is directory mode, check localPath and try create each layer
530 WRITE_LOG(LOG_DEBUG, "CheckDirectory localPath = %s optName = %s", localPath.c_str(), optName.c_str());
537 int r = uv_fs_lstat(nullptr, &req, localPath.c_str(), nullptr);
544 Base::SplitString(localPath, split, dirsOflocalPath);
546 WRITE_LOG(LOG_DEBUG, "localPath = %s dir layers = %zu", localPath.c_str(), dirsOflocalPath.size());
549 if (!Base::IsAbsolutePath(localPath)) {
574 WRITE_LOG(LOG_WARN, "Not a directory, path:%s", localPath.c_str());
576 errStr += localPath.c_str();
582 bool HdcTransferBase::CheckFilename(string &localPath, string &optName, string &errStr)
584 string localPathBackup = localPath;
609 // Add each layer directory to localPath
610 localPath = localPath + Base::GetPathSep() + s;
611 if (!Base::TryCreateDirectory(localPath, errStr)) {
615 string resolvedPath = Base::CanonicalizeSpecPath(localPath);
629 uv_fs_chmod(nullptr, &fs, localPath.c_str(), mode.perm, nullptr);
630 uv_fs_chown(nullptr, &fs, localPath.c_str(), mode.uId, mode.gId, nullptr);
635 setfilecon(localPath.c_str(), mode.context.c_str());
643 WRITE_LOG(LOG_DEBUG, "CheckFilename finish localPath:%s optName:%s", localPath.c_str(), optName.c_str());
649 bool HdcTransferBase::SmartSlavePath(string &cwd, string &localPath, const char *optName)
654 ExtractRelativePath(cwd, localPath);
657 if (Base::CheckDirectoryOrPath(localPath.c_str(), true, false, errStr, mode)) {
663 int r = uv_fs_lstat(nullptr, &req, localPath.c_str(), nullptr);
666 localPath = localPath + Base::GetPathSep() + optName;
668 if (r != 0 && (localPath.back() == Base::GetPathSep())) { // not exist and is dir
669 localPath = localPath + optName;