summaryrefslogtreecommitdiff
path: root/bin/bbackupd/BackupClientDirectoryRecord.cpp
Commit message (Collapse)AuthorAge
* Refactor SyncDirectory to reduce indentation and method length.Chris Wilson2014-12-10
| | | | | Move most of the code for handling individual directory entries into a separate method, SyncDirectoryEntry.
* Fix class member initialisation order to silence warnings.Chris Wilson2014-12-10
|
* Reformat long lines for readability, fix whitespace errors.Chris Wilson2014-12-10
|
* Log a consistent error message about every read failure, for debugging.Chris Wilson2014-12-10
|
* Whitespace and comment formatting fixes.Chris Wilson2014-12-10
|
* Add the new object ID to NotifyFileUploaded messages.Chris Wilson2014-09-04
|
* Add EstimatedBytesToUpload to NotifyFileUploadingPatch.Chris Wilson2014-09-04
| | | | Merged back changes from the test refactor branch to reduce diffs.
* Changed many uses of BackupProtocolClient to BackupProtocolCallable.Chris Wilson2014-09-04
| | | | | | Makes way for more use of local protocol objects and protocol subclasses. Merged back changes from the test refactor branch to reduce diffs.
* Simplify code with macros, update comments and fix whitespace.Chris Wilson2014-09-04
| | | | | | Hopefully all of these changes are inconsequential. Merged back changes from the test refactor branch to reduce diffs.
* Fix deadlock waiting for read or write on closed connection.Chris Wilson2014-08-15
| | | | | | | | If the system is suspended then it may not realise that a TCP connection has been closed, while waiting for data to arrive on it. We didn't used to apply a timeout to this read operation. Now we use the connection's default timeout on all read and write operations. Network operations that don't pass a timeout will be logged with a backtrace, so that they can be fixed.
* Use std::auto_ptrs instead of bare pointers for exclude lists.Chris Wilson2014-08-15
| | | | | Allows us to remove code to handle cleanups after exceptions and on Location destruction.
* Move code for creating/renaming remote dir to match local dir into own method.Chris Wilson2014-08-15
| | | | | | | | Reduces code indentation, scope leakage, and length of a long method. Conflicts: bin/bbackupd/BackupClientDirectoryRecord.h
* Rename rFilename argument to BackupClientDirectoryRecord::UploadFile, add ↵Chris Wilson2014-08-15
| | | | | | | | | | | remote path. rFilename renamed to rLocalPath to improve code clarity. rRemotePath added to allow it to be passed to notifier methods. Conflicts: bin/bbackupd/BackupClientDirectoryRecord.cpp
* Whitespace, wrapping, comments and dead code cleanups.Chris Wilson2014-08-15
| | | | | | | | Conflicts: bin/bbackupd/BackupDaemon.cpp bin/bbackupd/BackupDaemon.h test/bbackupd/testbbackupd.cpp
* Trailing whitespace fixes.Chris Wilson2014-08-15
| | | | | | Conflicts: bin/bbackupd/BackupClientDirectoryRecord.cpp
* Fix crash uploading empty attributes when directory disappears during scan.Chris Wilson2014-04-26
| | | | | Thanks to Brendon Baumgartner for the report on the mailing list, and for helping to diagnose the problem.
* Call RunBackgroundTask while scanning directories as well.Chris Wilson2014-04-17
| | | | | Enables bbackupd to be stopped, reloaded or status queried while scanning a large directory.
* Fix warnings about member variables being initialised in a different order.Chris Wilson2014-04-17
|
* Poll command socket regularly during file uploads.Chris Wilson2014-04-09
| | | | | Makes the daemon responsive to polling and commands, even during a file upload operation.
* Simplify exception handling by using std::auto_ptr.Chris Wilson2014-02-27
| | | | | Will result in the directory automatically being freed, whether or not an exception occurs.
* Pass std::auto_ptr objects to Protocol for upload.Chris Wilson2013-08-22
| | | | | | | | | | | Passing raw pointers is bad C++ style, and dangerous, because Protocol will free the passed-in pointers after uploading them, so we should not keep using them. Reduce code duplication in BackupClientDirectoryRecord patch/normal upload. Return a std::auto_ptr<BackupStoreFileEncodeStream> instead of a std::auto_ptr<IOStream> from BackupStoreFile::EncodeFile* functions.
* Treat corrupt filenames (not decryptable) as not existing, so thatChris Wilson2012-04-15
| | | | | | | | | the client will flag them for deletion, and the store will eventually prune them. We could probably recover better by flagging them for immediate deletion (Remove_ASAP) but this is a better-tested code path. Remove unused variable hasMultipleHardLinks.
* Improve logging when decrypting a filename fails during UpdateItems().Chris Wilson2012-04-11
|
* Add experimental "TCP Nice" mode, disabled by default.Chris Wilson2012-02-12
|
* Add missing space in log message for readability.Chris Wilson2012-02-02
|
* Fix logging of real (non-VSS) paths in UploadFile*.Chris Wilson2011-10-25
|
* Add debug logging for conversion from VSS to real path.Chris Wilson2011-10-24
|
* Convert VSS path to original path for log messages in UpdateItems, toChris Wilson2011-10-11
| | | | | help admins to interpret them.
* Fix excludions on VSS paths by converting back to original namespace beforeChris Wilson2011-10-11
| | | | | checking for them. Also simplifies code.
* Use "more standard" Windows API functions FindFirstFileW and FindNextFileWChris Wilson2011-08-28
| | | | | | | | | | for directory enumeration instead of _wfindfirst and _wfindnext. Ignore reparse points when enumerating directories to avoid infinite loops. Convert VSS paths back to real paths when notifying users about backup progress.
* Combine client and server protocols to make way for an offline/local protocol.Chris Wilson2011-08-27
| | | | | Rename ProtocolObject to Message.
* Log the number of files uploaded and directories created, as requested by ↵Chris Wilson2011-08-27
| | | | Achim, closes #61.
* Correct formatting of log message (missing bracket).Chris Wilson2011-08-27
|
* Warn users if a file with multiple hard links is encountered during backup.Chris Wilson2011-07-29
|
* There is no S_FIFO on Windows, fixes MSVC compile.Chris Wilson2011-03-26
|
* Rate limit file uploads using the configured MaxUploadRate, if any.Chris Wilson2011-01-12
|
* Workaround for apparent btrfs bug, where symlinks appear to be on aChris Wilson2011-01-09
| | | | | | | | different filesystem than their containing directory, by only checking for a different filesystem when checking directories, because files and special files can't be mount points anyway. Thanks to Toke Hoiland-Jorgensen.
* Log the device and inode numbers of directories and their entries whileChris Wilson2010-11-17
| | | | | scanning them, to debug Toke's report of symlinks appearing to be mounts.
* Log the total number of bytes uploaded to the server for each file.Chris Wilson2010-11-17
|
* Don't back up sockets and pipes, thanks to Mick Kappenburg for spotting Chris Wilson2010-05-20
| | | | | that the fix for Debian bug was incorrect.
* Notify about uploading changed attributes for files as well as Chris Wilson2010-02-24
| | | | | directories.
* Add notification about uploading new file attributes.Chris Wilson2010-02-24
| | | | | | Add check for changing file creation times on Windows, to cause the attributes to be uploaded again.
* Add missing space before file age in not uploading log message.Chris Wilson2009-11-26
|
* Ignore stat() errors on excluded directories.Chris Wilson2009-06-22
|
* Change type of BackupStoreFilename not to derive from std::string, soChris Wilson2009-03-29
| | | | | | | | it can't accidentally be used as one. Fix use of encrypted filename in deleted file message, thanks to Kenny Millington for reporting.
* Fix tests (hopefully) on Win32 for struct stat ino_t change from 16 toChris Wilson2009-03-21
| | | | | 64 bits.
* Catch exceptions from BackupClientFileAttributes::ReadAttributesChris Wilson2008-12-05
| | | | | | | | | | | | | | | | | during backup, and report which file caused them. If we cannot read the attributes of a directory to find its inode number, assume that it hasn't been renamed. Reformat "Storing uploaded file ID" log line to shorten source code lines. Change "Storing uploaded file ID" and "Found conflicting parent ID" messages not to print the path, which duplicates data earlier in the same message. Fix typo in comment.
* Fix missing parentheses on stored file ID messages.Chris Wilson2008-12-01
|
* Reformat comments for readability.Chris Wilson2008-10-03
|
* Log creation of directory records and warn on conflicting records.Chris Wilson2008-10-03
|