[ofw] [PATCH] winmad zero input struct prior to use
Smith, Stan
stan.smith at intel.com
Fri Apr 16 09:57:34 PDT 2010
In function WmRegInit() clear stack allocated input structs prior to use.
signed-off-by: sean hefty <sean.hefty at intel.com>
stan smith <stan.smith at intel.com>
--- a/core/winmad/kernel/wm_reg.c Fri Apr 16 08:54:19 2010
+++ b/core/winmad/kernel/wm_reg.c Fri Apr 02 10:16:13 2010
@@ -148,6 +148,7 @@
goto err4;
}
+ RtlZeroMemory(&svc, sizeof svc);
svc.mad_svc_context = pRegistration;
svc.pfn_mad_send_cb = WmSendHandler;
svc.pfn_mad_recv_cb = WmReceiveHandler;
@@ -164,6 +165,7 @@
}
if (svc.mgmt_class == IB_MCLASS_SUBN_DIR && svc.support_unsol) {
+ RtlZeroMemory(&port_cap, sizeof port_cap);
port_cap.cap.sm = 1;
ib_status = dev->IbInterface.modify_ca(pRegistration->hCa,
pRegistration->PortNum,
Committed in
Revision: 2795
Author: stansmith
Date: 9:50:31 AM, Friday, April 16, 2010
Message:
[WINMAD] clear input structs prior to use.
----
Modified : /gen1/trunk/core/winmad/kernel/wm_reg.c
More information about the ofw
mailing list