Home | History | Annotate | Download | only in base

Lines Matching refs:from_path

186 bool Move(const FilePath& from_path, const FilePath& to_path) {
188 // Windows compatibility: if to_path exists, from_path and to_path
193 if (CallStat(from_path.value().c_str(), &from_file_info) == 0) {
201 if (rename(from_path.value().c_str(), to_path.value().c_str()) == 0)
204 if (!CopyDirectory(from_path, to_path, true))
207 Delete(from_path, true);
211 bool ReplaceFile(const FilePath& from_path, const FilePath& to_path) {
213 return (rename(from_path.value().c_str(), to_path.value().c_str()) == 0);
216 bool CopyDirectory(const FilePath& from_path,
225 DCHECK(from_path.value().find('*') == std::string::npos);
228 if (base::strlcpy(top_dir, from_path.value().c_str(),
243 FilePath real_from_path = from_path;
258 FileEnumerator traversal(from_path, recursive, traverse_type);
263 FilePath current = from_path;
264 if (stat(from_path.value().c_str(), &info.stat) < 0) {
266 from_path.value() << " errno = " << errno;
270 FilePath from_path_base = from_path;
275 from_path_base = from_path.DirName();
279 // will always have a directory for from_path.
283 // current is the source path, including from_path, so paste
284 // the suffix after from_path onto to_path to create the target_path.
850 bool CopyFile(const FilePath& from_path, const FilePath& to_path) {
852 int infile = HANDLE_EINTR(open(from_path.value().c_str(), O_RDONLY));