search for: mkdir_defmode

Displaying 4 results from an estimated 4 matches for "mkdir_defmode".

2010 Nov 09
5
Changes made to main.c on implementing real time Rsync
...11) at main.c(577) [Receiver=3.0.7] rsync: connection unexpectedly closed (5 bytes received so far) [sender] rsync error: error in rsync protocol data stream (code 12) at io.c(610) [sender=3.0.7] So, I changed main.c to create folder recursively. The following are the changes. if (mkdir_defmode(dest_path) != 0) { /*create folder recursively*/ char parentFolder[200]; char *pFound = dest_path + 1;//ignore the first / STRUCT_STAT st1; while( (pFound = strchr(pFound, '/')) != NULL)...
2010 Mar 08
1
Getting EEXIST out of make_bak_dir()
...paranoia */ if (errno == ENOENT && make_bak_dir(backupptr) == 0) { Does make_bak_dir simply need to trap for that error, like: /* Try to find an existing dir, starting from the deepest dir. */ while (1) { if (--p == fbuf) return -1; if (*p == '/') { *p = '\0'; if (mkdir_defmode(fbuf) == 0 || errno == EEXIST) // <-- Trap for EEXIST? break; if (errno != ENOENT) { rsyserr(FERROR, errno, "make_bak_dir mkdir %s failed", full_fname(fbuf)); return -1; } } } Thanks, Mike -------------- next part -------------- An HTML attachment was scrubbed.....
2006 Nov 21
1
rsync v2.6.9: small patch fixing NORETURN failures
...ir(int fd[2]); void print_child_argv(char **cmd); -NORETURN void out_of_memory(char *str); -NORETURN void overflow_exit(char *str); +NORETURN void out_of_memory(char *str) NORETURN2; +NORETURN void overflow_exit(char *str) NORETURN2; int set_modtime(char *fname, time_t modtime, mode_t mode); int mkdir_defmode(char *fname); int create_directory_path(char *fname); --- rsync-2.6.9/rsync.h.orig 2006-10-24 05:31:30.000000000 +0200 +++ rsync-2.6.9/rsync.h 2006-11-21 21:32:09.000000000 +0100 @@ -667,7 +667,16 @@ #endif #define UNUSED(x) x __attribute__((__unused__)) +#if __GNUC__ > 2 #define NORETURN...
2008 Mar 04
1
Several changes missing from [HEAD] fileflags.diff
...efix, char **cmd); > NORETURN void out_of_memory(const char *str); > NORETURN void overflow_exit(const char *str); > -int set_modtime(const char *fname, time_t modtime, mode_t mode); > +int set_modtime(const char *fname, time_t modtime, mode_t mode, > uint32 fileflags); > int mkdir_defmode(char *fname); > int create_directory_path(char *fname); > int full_write(int desc, const char *ptr, size_t len); > diff -up a/rsync.1 b/rsync.1 > --- a/rsync.1 > +++ b/rsync.1 > @@ -413,6 +413,7 @@ to the detailed description below for a > \-K, \-\-keep\-dirlinks tr...