[SCM] Samba Shared Repository - branch v3-2-test updated -
release-3-2-0pre2-3237-g00af692
Jeremy Allison
jra at samba.org
Mon Dec 8 22:04:47 GMT 2008
The branch, v3-2-test has been updated
via 00af69227dbdd6dfd3776b5cb52f479c9c85b697 (commit)
from 66c08857fbf78a24e7770e1d1bf8938bb938b271 (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-test
- Log -----------------------------------------------------------------
commit 00af69227dbdd6dfd3776b5cb52f479c9c85b697
Author: Jeremy Allison <jra at samba.org>
Date: Mon Dec 8 14:02:59 2008 -0800
Fix bug #5953 - smbclient crashes: cli_list_new segmentation fault.
Karolin: must be in 3.2-stable. Thanks,
Jeremy.
-----------------------------------------------------------------------
Summary of changes:
source/libsmb/clilist.c | 2 +-
source/smbd/vfs.c | 8 +++++++-
2 files changed, 8 insertions(+), 2 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source/libsmb/clilist.c b/source/libsmb/clilist.c
index 5091845..cebafc6 100644
--- a/source/libsmb/clilist.c
+++ b/source/libsmb/clilist.c
@@ -417,7 +417,7 @@ int cli_list_new(struct cli_state *cli,const char *Mask,uint16 attribute,
}
SAFE_FREE(mask);
- if (ff_searchcount > 0) {
+ if (ff_searchcount > 0 && ff_eos == 0 && finfo.name) {
mask = SMB_STRDUP(finfo.name);
} else {
mask = SMB_STRDUP("");
diff --git a/source/smbd/vfs.c b/source/smbd/vfs.c
index 33a3a43..6cf156c 100644
--- a/source/smbd/vfs.c
+++ b/source/smbd/vfs.c
@@ -624,6 +624,9 @@ int vfs_fill_sparse(files_struct *fsp, SMB_OFF_T len)
flush_write_cache(fsp, SIZECHANGE_FLUSH);
+#ifdef HAVE_POSIX_FALLOCATE
+ set_filelen_write_cache(fsp, len);
+#else
if (!sparse_buf) {
sparse_buf = SMB_CALLOC_ARRAY(char, SPARSE_BUF_WRITE_SIZE);
if (!sparse_buf) {
@@ -652,8 +655,11 @@ int vfs_fill_sparse(files_struct *fsp, SMB_OFF_T len)
total += pwrite_ret;
}
+ ret = 0;
+#endif
+
set_filelen_write_cache(fsp, len);
- return 0;
+ return ret;
}
/****************************************************************************
--
Samba Shared Repository
More information about the samba-cvs
mailing list