Piotr Caban : msvcrt: Remove no longer needed global lock from functions using fd critical sections.
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Jun 11 09:46:11 CDT 2015
Module: wine
Branch: master
Commit: 725e4733cf83305ac3b4ae3cb949a68f5a75e773
URL: http://source.winehq.org/git/wine.git/?a=commit;h=725e4733cf83305ac3b4ae3cb949a68f5a75e773
Author: Piotr Caban <piotr at codeweavers.com>
Date: Wed Jun 10 17:48:42 2015 +0200
msvcrt: Remove no longer needed global lock from functions using fd critical sections.
---
dlls/msvcrt/file.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/dlls/msvcrt/file.c b/dlls/msvcrt/file.c
index 802834c..1069cf7 100644
--- a/dlls/msvcrt/file.c
+++ b/dlls/msvcrt/file.c
@@ -1009,7 +1009,6 @@ int CDECL MSVCRT__close(int fd)
ioinfo *info = get_ioinfo(fd);
int ret;
- LOCK_FILES();
TRACE(":fd (%d) handle (%p)\n", fd, info->handle);
if (!(info->wxflag & WX_OPEN)) {
ret = -1;
@@ -1021,7 +1020,6 @@ int CDECL MSVCRT__close(int fd)
msvcrt_set_errno(GetLastError());
}
}
- UNLOCK_FILES();
release_ioinfo(info);
return ret;
}
@@ -1039,7 +1037,6 @@ int CDECL MSVCRT__dup2(int od, int nd)
int ret;
TRACE("(od=%d, nd=%d)\n", od, nd);
- LOCK_FILES();
if (od < nd)
{
@@ -1086,7 +1083,6 @@ int CDECL MSVCRT__dup2(int od, int nd)
release_ioinfo(info_od);
release_ioinfo(info_nd);
- UNLOCK_FILES();
return ret;
}
@@ -2065,7 +2061,6 @@ int CDECL MSVCRT__pipe(int *pfds, unsigned int psize, int textmode)
unsigned int wxflags = split_oflags(textmode);
int fd;
- LOCK_FILES();
fd = msvcrt_alloc_fd(readHandle, wxflags|WX_PIPE);
if (fd != -1)
{
@@ -2089,7 +2084,6 @@ int CDECL MSVCRT__pipe(int *pfds, unsigned int psize, int textmode)
CloseHandle(writeHandle);
*MSVCRT__errno() = MSVCRT_EMFILE;
}
- UNLOCK_FILES();
}
else
msvcrt_set_errno(GetLastError());
More information about the wine-cvs
mailing list