]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix bug where open() mode was not being set based on type of device being emulated.
authorandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>
Sat, 7 Jan 2012 00:30:52 +0000 (00:30 +0000)
committerandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>
Sat, 7 Jan 2012 00:30:52 +0000 (00:30 +0000)
signed-off-by:andrewfish

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12917 6f19259b-4bc3-4df7-8a09-765794883524

EmulatorPkg/Unix/Host/BlockIo.c

index 50fe9b575e10c140f0ada79daca258c26fd676e1..fa05fbc107d1c5e699cd34ab464a940b7afd229a 100644 (file)
@@ -661,6 +661,8 @@ EmuBlockIoThunkOpen (
     }\r
   }\r
 \r
+  Private->Mode = Private->WriteProtected ? O_RDONLY : O_RDWR;\r
+\r
   This->Interface = &Private->EmuBlockIo;\r
   This->Private   = Private;\r
   return EFI_SUCCESS;\r