The Samba-Bugzilla – Attachment 3174 Details for
Bug 5309
double free or corruption while using rsync 3.0.0 stable
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Fixed a crash bug in the backup code
crash-fix.patch (text/plain), 1.44 KB, created by
Wayne Davison
on 2008-03-15 02:48:43 UTC
(
hide
)
Description:
Fixed a crash bug in the backup code
Filename:
MIME Type:
Creator:
Wayne Davison
Created:
2008-03-15 02:48:43 UTC
Size:
1.44 KB
patch
obsolete
>--- a/flist.c >+++ b/flist.c >@@ -1123,8 +1123,14 @@ struct file_struct *make_file(const char *fname, struct file_list *flist, > pool = dir_flist->file_pool; > } else > pool = flist->file_pool; >- } else >+ } else { >+#ifdef SUPPORT_ACLS >+ /* Directories need an extra int32 for the default ACL. */ >+ if (preserve_acls && S_ISDIR(st.st_mode)) >+ extra_len += EXTRA_LEN; >+#endif > pool = NULL; >+ } > > if (verbose > 2) { > rprintf(FINFO, "[%s] make_file(%s,*,%d)\n", >@@ -1219,7 +1225,10 @@ struct file_struct *make_file(const char *fname, struct file_list *flist, > if (always_checksum && am_sender && S_ISREG(st.st_mode)) > file_checksum(thisname, tmp_sum, st.st_size); > >- F_PATHNAME(file) = pathname; >+ if (am_sender) >+ F_PATHNAME(file) = pathname; >+ else if (!pool) >+ F_DEPTH(file) = extra_len / EXTRA_LEN; > > /* This code is only used by the receiver when it is building > * a list of files for a delete pass. */ >@@ -1255,12 +1264,7 @@ struct file_struct *make_file(const char *fname, struct file_list *flist, > /* Only called for temporary file_struct entries created by make_file(). */ > void unmake_file(struct file_struct *file) > { >- int extra_cnt = file_extra_cnt + LEN64_BUMP(file); >-#if EXTRA_ROUNDING > 0 >- if (extra_cnt & EXTRA_ROUNDING) >- extra_cnt = (extra_cnt | EXTRA_ROUNDING) + 1; >-#endif >- free(REQ_EXTRA(file, extra_cnt)); >+ free(REQ_EXTRA(file, F_DEPTH(file))); > } > > static struct file_struct *send_file_name(int f, struct file_list *flist,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 5309
: 3174