git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7ed3868
)
r13222: Never assume mode_t is of type int.
author
Simo Sorce
<idra@samba.org>
Sun, 29 Jan 2006 18:22:39 +0000
(18:22 +0000)
committer
Gerald (Jerry) Carter
<jerry@samba.org>
Wed, 10 Oct 2007 16:06:18 +0000
(11:06 -0500)
We were trashing the stack on machines that define mode_t as uint16_t
(This used to be commit
6c15af31bcee1e82578b61cae10423b37c285f10
)
source3/modules/vfs_recycle.c
patch
|
blob
|
history
diff --git
a/source3/modules/vfs_recycle.c
b/source3/modules/vfs_recycle.c
index 28593f4fbb72a5126e662bc6d26a6828cfe3a2df..188c50be3e54e93b205c3c5943f5474c00c7f47f 100644
(file)
--- a/
source3/modules/vfs_recycle.c
+++ b/
source3/modules/vfs_recycle.c
@@
-166,13
+166,13
@@
static int recycle_maxsize(vfs_handle_struct *handle)
static mode_t recycle_directory_mode(vfs_handle_struct *handle)
{
-
mode_
t dirmode;
+
in
t dirmode;
const char *buff;
buff = lp_parm_const_string(SNUM(handle->conn), "recycle", "directory_mode", NULL);
if (buff != NULL ) {
- sscanf(buff, "%o",
(int *)
&dirmode);
+ sscanf(buff, "%o", &dirmode);
} else {
dirmode=S_IRUSR | S_IWUSR | S_IXUSR;
}