https://git.reactos.org/?p=reactos.git;a=commitdiff;h=33fc7bf316fd35aafffa9…
commit 33fc7bf316fd35aafffa9025a78fd09ac670448c
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Thu Aug 30 07:50:06 2018 +0900
Commit: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito(a)reactos.org>
CommitDate: Thu Aug 30 00:50:06 2018 +0200
[STORAHCI] Fix MSVC "uninitialized local variable" error (C4700) (#828)
See also PR #821.
---
drivers/storage/storahci/storahci.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/drivers/storage/storahci/storahci.c b/drivers/storage/storahci/storahci.c
index 54931ac6ff..c674b2b7af 100644
--- a/drivers/storage/storahci/storahci.c
+++ b/drivers/storage/storahci/storahci.c
@@ -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