[ros-dev] RE: [ros-diffs] [weiden] 13188: fixed ASSERT statement, thanks to blight for pointing it out

Casper Hornstrup ch at csh-consult.dk
Fri Jan 21 19:01:57 CET 2005


If we

#define ASSERT(x) if (0) { x }

for DBG := 0, won't all these compile errors go away? We have a lot of them.
The compiler will perform syntax check, but optimize the statements away.

Casper
________________________________

	From: ros-diffs-bounces at reactos.com [mailto:ros-diffs-bounces at reactos.com] On Behalf Of weiden at svn.reactos.com
	Sent: 21. januar 2005 18:17
	To: ros-diffs at reactos.com
	Subject: [ros-diffs] [weiden] 13188: fixed ASSERT statement,thanks to blight for pointing it out
	
	
	fixed ASSERT statement, thanks to blight for pointing it out
	Modified: trunk/reactos/ntoskrnl/ob/object.c
	
________________________________

	Modified: trunk/reactos/ntoskrnl/ob/object.c
	--- trunk/reactos/ntoskrnl/ob/object.c	2005-01-21 16:50:11 UTC (rev 13187)
	+++ trunk/reactos/ntoskrnl/ob/object.c	2005-01-21 17:17:13 UTC (rev 13188)
	@@ -51,7 +51,7 @@
	
	   NTSTATUS Status = STATUS_SUCCESS;
	   
	   /* at least one output parameter must be != NULL! */
	
	-  ASSERT((ULONG_PTR)SecureObjectInformation ^ (ULONG_PTR)ObjectName != 0);
	
	+  ASSERT((ULONG_PTR)CapturedObjectAttributes ^ (ULONG_PTR)ObjectName != 0);
	
	   
	   if(ObjectAttributes == NULL)
	   {
	




More information about the Ros-dev mailing list