bool IsOnVideoDirectoryFileSystem(const char *FileName) { cVideoDirectory Dir; do { if (EntriesOnSameFileSystem(Dir.Name(), FileName)) return true; } while (Dir.Next()); return false; }
bool cVideoDirectory::Move(const char *FromName, const char *ToName) { dsyslog("moving '%s' to '%s'", FromName, ToName); if (EntriesOnSameFileSystem(FromName, ToName)) { if (rename(FromName, ToName) == -1) { LOG_ERROR_STR(ToName); return false; } } else return RecordingsHandler.Add(ruMove, FromName, ToName); return true; }
bool cVideoDirectory::Contains(const char *Name) { return EntriesOnSameFileSystem(this->Name(), Name); }