From 3cdb02f964241fe8f2f1c8d286108606ef54e4dd Mon Sep 17 00:00:00 2001 From: lpleahy Date: Fri, 8 Feb 2013 21:26:46 +0000 Subject: [PATCH] Fix sockets use of file descriptors which was broken by the additional validation in StdLib/LibC/Uefi/SysCall.c/write added by revision 13989. Signed-off-by: lpleahy git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14123 6f19259b-4bc3-4df7-8a09-765794883524 --- StdLib/BsdSocketLib/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/StdLib/BsdSocketLib/socket.c b/StdLib/BsdSocketLib/socket.c index 4f49777b51..6b00f41f40 100644 --- a/StdLib/BsdSocketLib/socket.c +++ b/StdLib/BsdSocketLib/socket.c @@ -146,7 +146,7 @@ BslSocketProtocolToFd ( pDescriptor->f_flag = 0; pDescriptor->f_iflags = DTYPE_SOCKET; pDescriptor->MyFD = (UINT16)FileDescriptor; - pDescriptor->Oflags = 0; + pDescriptor->Oflags = O_RDWR; pDescriptor->Omode = S_ACC_READ | S_ACC_WRITE; pDescriptor->RefCount = 1; FILE_SET_MATURE ( pDescriptor );