[STORAHCI] Fix MSVC "uninitialized local variable" error (C4700) (#828)
authorKatayama Hirofumi MZ <katayama.hirofumi.mz@gmail.com>
Wed, 29 Aug 2018 22:50:06 +0000 (07:50 +0900)
committerHermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
Wed, 29 Aug 2018 22:50:06 +0000 (00:50 +0200)
See also PR #821.

drivers/storage/storahci/storahci.c

index 54931ac..c674b2b 100644 (file)
@@ -1480,6 +1480,12 @@ AhciProcessSrb (
  * @param PortExtension
  *
  */
+
+#ifdef _MSC_VER     // avoid MSVC C4700
+    #pragma warning(push)
+    #pragma warning(disable: 4700)
+#endif
+
 VOID
 AhciActivatePort (
     __in PAHCI_PORT_EXTENSION PortExtension
@@ -1529,6 +1535,10 @@ AhciActivatePort (
     return;
 }// -- AhciActivatePort();
 
+#ifdef _MSC_VER     // avoid MSVC C4700
+    #pragma warning(pop)
+#endif
+
 /**
  * @name AhciProcessIO
  * @implemented