Displaying 15 results from an estimated 15 matches for "cleanup_got_literal".
2006 May 18
1
Partial files left on SIGINT
Hi,
As the man page says, the --partial flag is to "keep partially
transferred files". I'm assuming if I don't have partial flag any
partially transferred files should be deleted. However this is not what
I'm seeing.
Example:
(Using a big file so that rsync times a while to run. This gives me time
to hit CTRL-C for the SIGINT).
> mkdir example
> dd if=/dev/zero
2004 Jan 13
3
Progress reporting: N more to check
...,6 +328,9 @@ int recv_files(int f_in,struct file_list
file = flist->files[i];
+ if (phase == 0)
+ stats.num_untransferred_files += i - stats.current_file_index - 1;
+ stats.current_file_index = i;
stats.num_transferred_files++;
stats.total_transferred_size += file->length;
cleanup_got_literal = 0;
--- rsync.h 12 Jan 2004 03:48:43 -0000 1.170
+++ rsync.h 13 Jan 2004 06:17:50 -0000
@@ -477,6 +477,8 @@ struct stats {
int flist_size;
int num_files;
int num_transferred_files;
+ int num_untransferred_files;
+ int current_file_index;
};
--- sender.c 10 Jan 2004 20:16:18 -0000 1.32
+...
2009 Mar 11
0
Odd issue with locked directories and Mac OS X
...-11-15 16:49:28.000000000 -0600
+++ rsync-3.0.5/receiver.c 2009-03-10 22:18:20.000000000 -0500
@@ -39,6 +42,7 @@
extern int preserve_hard_links;
extern int preserve_perms;
extern int preserve_xattrs;
+extern int force_change;
extern int basis_dir_cnt;
extern int make_backups;
extern int cleanup_got_literal;
@@ -153,6 +157,20 @@
}
#endif
+#ifdef SUPPORT_FORCE_CHANGE
+ if (fd == -1) {
+ stat_x sx;
+ if (do_stat(file->dirname, &sx.st) < 0)
+ rprintf(FINFO, "Failed to stat %s!\n", full_fname(file->dirname));
+ else {
+ if (force_change && make_mutable(file->...
2008 Dec 05
0
rsync patch to allow content from one device file to be synced to another device file
...000000000 -0500
+++ rsync-HEAD-20081115-2333GMT-d2d/receiver.c 2008-12-04
17:01:00.000000000 -0500
@@ -38,6 +38,7 @@
extern int preserve_hard_links;
extern int preserve_perms;
extern int preserve_xattrs;
+extern int copy_devices;
extern int basis_dir_cnt;
extern int make_backups;
extern int cleanup_got_literal;
@@ -285,7 +286,7 @@
goto report_write_error;
#ifdef HAVE_FTRUNCATE
- if (inplace && fd != -1
+ if (inplace && !copy_devices && fd != -1
&& ftruncate(fd, offset) < 0) {
rsyserr(FERROR_XFER, errno, "ftrunc...
2004 Apr 27
1
rsync-2.6.1 close() fixes
...f you are transferring _many_ files.
-f and --fsync options added to rsync for the paranoids.
--
-------------- next part --------------
--- rsync-2.6.1/receiver.c.bak 2004-03-23 18:50:40.000000000 +0200
+++ rsync-2.6.1/receiver.c 2004-04-27 19:11:46.000000000 +0300
@@ -45,6 +45,7 @@ extern int cleanup_got_literal;
extern int module_id;
extern int ignore_errors;
extern int orig_umask;
+extern int do_fsync;
static void delete_one(char *fn, int is_dir)
{
@@ -268,6 +269,12 @@ static int receive_data(int f_in,struct
exit_cleanup(RERR_FILEIO);
}
+ if (do_fsync && (fd != -1) && (fsyn...
2009 Jan 24
2
[patch] Replace illegal characters in filenames for FAT (switch)
...ceiver.c
index 4325e30..bc9dc90 100644
--- a/receiver.c
+++ b/receiver.c
@@ -38,6 +38,7 @@ extern int relative_paths;
extern int preserve_hard_links;
extern int preserve_perms;
extern int preserve_xattrs;
+extern int fat_filenames;
extern int basis_dir_cnt;
extern int make_backups;
extern int cleanup_got_literal;
@@ -441,6 +442,8 @@ int recv_files(int f_in, char *local_name)
const char *parent_dirname = "";
#endif
int ndx, recv_ok;
+ int i;
+ static const char fat_invalid_chars[] = "*/:<>?\\|\"";
if (DEBUG_GTE(RECV, 1))
rprintf(FINFO, "recv_files(%d) st...
2009 Nov 04
0
PATCH: fast copy of files in local server mode
...r *)&offset, sizeof(offset));
+ if (i <= 0)
+ return 0;
+ f_in = -i;
+ }
+
if (fd_r >= 0 && size_r > 0) {
int32 read_size = MAX(sum.blength * 2, 16*1024);
mapbuf = map_file(fd_r, size_r, read_size, sum.blength);
@@ -231,11 +245,18 @@
stats.literal_data += i;
cleanup_got_literal = 1;
- sum_update(data, i);
+ if (f_in >= 0)
+ /* no need for md4 during fast copy -goldor */
+ sum_update(data, i);
if (fd != -1 && write_file(fd,data,i) != i)
goto report_write_error;
offset += i;
+ if (f_in < 0 && percent < offset * 100 / tot...
2006 Jun 02
3
[PATCH] --omit-dir-changes, qsort<>mergesort issues
...eceiver.c
--- receiver.c 1 Jun 2006 08:04:50 -0000 1.181
+++ receiver.c 2 Jun 2006 13:00:01 -0000
@@ -37,6 +37,7 @@
extern int relative_paths;
extern int preserve_hard_links;
extern int preserve_perms;
+extern int omit_dir_changes;
extern int basis_dir_cnt;
extern int make_backups;
extern int cleanup_got_literal;
@@ -541,7 +542,7 @@
/* If we're not preserving permissions, change the file-list's
* mode based on the local permissions and some heuristics. */
- if (!preserve_perms) {
+ if (!preserve_perms || (S_ISDIR(st.st_mode) && omit_dir_changes)) {
int exists = fd1 != -1;...
2004 Feb 09
1
[patch] Add `--link-by-hash' option.
...e,char *md4)
{
int i;
struct sum_struct sum;
+ struct mdfour mdfour_data;
unsigned int len;
OFF_T offset = 0;
OFF_T offset2;
@@ -250,6 +251,8 @@
char *map=NULL;
read_sum_head(f_in, &sum);
+ if (md4)
+ mdfour_begin(&mdfour_data);
sum_init();
@@ -269,6 +272,8 @@
cleanup_got_literal = 1;
sum_update(data,i);
+ if (md4)
+ mdfour_update(&mdfour_data,data,i);
if (fd != -1 && write_file(fd,data,i) != i) {
rprintf(FERROR, "write failed on %s: %s\n",
@@ -296,6 +301,8 @@
see_token(map, len);
sum_update(map,len);
+ if (md4...
2004 Jan 17
1
--delete-sent-files (AKA --move-files)
...local(int s, int ai_family, int ai_socktype,
const char *bind_address);
Index: receiver.c
--- receiver.c 15 Jan 2004 07:42:25 -0000 1.63
+++ receiver.c 17 Jan 2004 05:04:55 -0000
@@ -39,6 +39,7 @@ extern char *backup_dir;
extern char *backup_suffix;
extern int backup_suffix_len;
extern int cleanup_got_literal;
+extern int delete_sent_files;
static void delete_one(char *fn, int is_dir)
{
@@ -287,7 +288,7 @@ int recv_files(int f_in,struct file_list
char *fname, fbuf[MAXPATHLEN];
char template[MAXPATHLEN];
char fnametmp[MAXPATHLEN];
- char *fnamecmp;
+ char *fnamecmp, numbuf[4];
char fnamecmpbu...
2004 Feb 23
0
[patch] Add `--link-by-hash' option (rev 4).
...struct mdfour mdfour_data;
unsigned int len;
OFF_T offset = 0;
OFF_T offset2;
@@ -199,7 +200,9 @@
char *map=NULL;
read_sum_head(f_in, &sum);
-
+ if (md4)
+ mdfour_begin(&mdfour_data);
+
sum_init();
while ((i = recv_token(f_in, &data)) != 0) {
@@ -216,6 +219,8 @@
cleanup_got_literal = 1;
sum_update(data,i);
+ if (md4)
+ mdfour_update(&mdfour_data,data,i);
if (fd != -1 && write_file(fd,data,i) != i) {
rprintf(FERROR, "write failed on %s: %s\n",
@@ -243,6 +248,8 @@
see_token(map, len);
sum_update(map,len);
+ if (md4)
+ m...
2004 Feb 17
0
[patch] Add `--link-by-hash' option (rev 3).
...struct mdfour mdfour_data;
unsigned int len;
OFF_T offset = 0;
OFF_T offset2;
@@ -199,7 +200,9 @@
char *map=NULL;
read_sum_head(f_in, &sum);
-
+ if (md4)
+ mdfour_begin(&mdfour_data);
+
sum_init();
while ((i = recv_token(f_in, &data)) != 0) {
@@ -216,6 +219,8 @@
cleanup_got_literal = 1;
sum_update(data,i);
+ if (md4)
+ mdfour_update(&mdfour_data,data,i);
if (fd != -1 && write_file(fd,data,i) != i) {
rprintf(FERROR, "write failed on %s: %s\n",
@@ -243,6 +248,8 @@
see_token(map, len);
sum_update(map,len);
+ if (md4)
+ m...
2004 Feb 23
0
[patch] Add `--link-by-hash' option (rev 5).
...struct mdfour mdfour_data;
unsigned int len;
OFF_T offset = 0;
OFF_T offset2;
@@ -199,7 +200,9 @@
char *map=NULL;
read_sum_head(f_in, &sum);
-
+ if (md4)
+ mdfour_begin(&mdfour_data);
+
sum_init();
while ((i = recv_token(f_in, &data)) != 0) {
@@ -216,6 +219,8 @@
cleanup_got_literal = 1;
sum_update(data,i);
+ if (md4)
+ mdfour_update(&mdfour_data,data,i);
if (fd != -1 && write_file(fd,data,i) != i) {
rprintf(FERROR, "write failed on %s: %s\n",
@@ -243,6 +248,8 @@
see_token(map, len);
sum_update(map,len);
+ if (md4)
+ m...
2004 Feb 16
1
[patch] Add `--link-by-hash' option (rev 2).
...struct mdfour mdfour_data;
unsigned int len;
OFF_T offset = 0;
OFF_T offset2;
@@ -199,7 +200,9 @@
char *map=NULL;
read_sum_head(f_in, &sum);
-
+ if (md4)
+ mdfour_begin(&mdfour_data);
+
sum_init();
while ((i = recv_token(f_in, &data)) != 0) {
@@ -216,6 +219,8 @@
cleanup_got_literal = 1;
sum_update(data,i);
+ if (md4)
+ mdfour_update(&mdfour_data,data,i);
if (fd != -1 && write_file(fd,data,i) != i) {
rprintf(FERROR, "write failed on %s: %s\n",
@@ -243,6 +248,8 @@
see_token(map, len);
sum_update(map,len);
+ if (md4)
+ m...
2007 Sep 22
0
rsync build on IA64 using icc
...#1419: external declaration in primary source file
extern int basis_dir_cnt;
^
receiver.c(41): remark #1419: external declaration in primary source file
extern int make_backups;
^
receiver.c(42): remark #1419: external declaration in primary source file
extern int cleanup_got_literal;
^
receiver.c(43): remark #1419: external declaration in primary source file
extern int remove_source_files;
^
receiver.c(44): remark #1419: external declaration in primary source file
extern int append_mode;
^
receiver.c(45): remark #1419: external dec...