Module: wine Branch: stable Commit: d614927a10835d47eb5bd0f4b1c2dbe4f4b3dbd2 URL: https://source.winehq.org/git/wine.git/?a=commit;h=d614927a10835d47eb5bd0f4b...
Author: Gijs Vermeulen gijsvrm@gmail.com Date: Tue Mar 26 17:04:44 2019 +0100
hnetcfg: Initialize INetFwRules::get__NewEnum out parameter.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46906 Signed-off-by: Gijs Vermeulen gijsvrm@gmail.com Signed-off-by: Alexandre Julliard julliard@winehq.org (cherry picked from commit 16803516ef0967b1290bcdac269f4e157af163f1) Signed-off-by: Michael Stefaniuc mstefani@winehq.org
---
dlls/hnetcfg/policy.c | 4 ++++ dlls/hnetcfg/tests/policy.c | 3 +++ 2 files changed, 7 insertions(+)
diff --git a/dlls/hnetcfg/policy.c b/dlls/hnetcfg/policy.c index c2f3252..c549ead 100644 --- a/dlls/hnetcfg/policy.c +++ b/dlls/hnetcfg/policy.c @@ -238,6 +238,10 @@ static HRESULT WINAPI netfw_rules_get__NewEnum( fw_rules *This = impl_from_INetFwRules( iface );
FIXME("%p, %p\n", This, newEnum); + + if (!newEnum) return E_POINTER; + *newEnum = NULL; + return E_NOTIMPL; }
diff --git a/dlls/hnetcfg/tests/policy.c b/dlls/hnetcfg/tests/policy.c index 3fa8348..8701455 100644 --- a/dlls/hnetcfg/tests/policy.c +++ b/dlls/hnetcfg/tests/policy.c @@ -60,6 +60,9 @@ static void test_policy2_rules(INetFwPolicy2 *policy2) INetFwServiceRestriction_Release(restriction); }
+ hr = INetFwRules_get__NewEnum(rules, NULL); + ok(hr == E_POINTER, "got %08x\n", hr); + INetFwRules_Release(rules); INetFwRules_Release(rules2); }