[ofw] [PATCH] allow svr 2003 compilation
Alex Naslednikov
xalex at mellanox.co.il
Wed Jun 29 00:39:55 PDT 2011
Hello Stan,
Thanks for the catch. Please, apply
I did not tested it on 2003 because we (MLNX) will not support Win2003 at the next release
-----Original Message-----
From: Smith, Stan [mailto:stan.smith at intel.com]
Sent: Tuesday, June 28, 2011 9:21 PM
To: Alex Naslednikov
Cc: ofw at lists.openfabrics.org
Subject: [PATCH] allow svr 2003 compilation
Hello Alex,
Your patch did not compile for svr 2003 x86; I believe I captured in spirit what you wanted.
Signed-off-by: stan smith <stan.smith at intel.com>
--- C:/Users/scsmith/AppData/Local/Temp/al_dm.c-revBASE.svn000.tmp.c Tue Jun 28 11:12:33 2011
+++ C:/Users/scsmith/Documents/openIB-windows/SVN/gen1/trunk/core/al/al_dm.c Tue Jun 28 11:13:03 2011
@@ -765,17 +765,25 @@
reg_svc_req.svc_rec.service_lease = 0xffffffff; #ifdef CL_KERNEL
- RtlStringCchCopyA(
- (char*)reg_svc_req.svc_rec.service_name,
- sizeof(reg_svc_req.svc_rec.service_name),
- DM_SVC_NAME
- );
+ RtlStringCchCopyA(
+ (char*)reg_svc_req.svc_rec.service_name,
+ sizeof(reg_svc_req.svc_rec.service_name),
+ DM_SVC_NAME
+ );
#else
+#ifdef NTDDI_WIN8
strcpy_s(
(char*)reg_svc_req.svc_rec.service_name,
sizeof(reg_svc_req.svc_rec.service_name),
DM_SVC_NAME
);
+#else
+ strncpy(
+ (char*)reg_svc_req.svc_rec.service_name,
+ DM_SVC_NAME,
+ sizeof(DM_SVC_NAME)
+ );
+#endif
#endif
reg_svc_req.svc_rec.service_gid = p_iou_port->port_gid;
reg_svc_req.port_guid = p_iou_port->port_guid;
More information about the ofw
mailing list