[PATCH] server: Check whether the new file name is executable.
Zebediah Figura
z.figura12 at gmail.com
Mon Mar 30 00:12:18 CDT 2020
Fixes: 4a43546b341917072fd0faa60abd2360203ae533
Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
---
server/fd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/server/fd.c b/server/fd.c
index 5019ae2da00..d4584f73268 100644
--- a/server/fd.c
+++ b/server/fd.c
@@ -2438,7 +2438,7 @@ static void set_fd_name( struct fd *fd, struct fd *root, const char *nameptr,
if (is_file_executable( fd->unix_name ) != is_file_executable( name ) && !fstat( fd->unix_fd, &st ))
{
- if (is_file_executable( fd->unix_name ))
+ if (is_file_executable( name ))
/* set executable bit where read bit is set */
st.st_mode |= (st.st_mode & 0444) >> 2;
else
--
2.25.1
More information about the wine-devel
mailing list