don't dereference a NULL pointer
authorThomas Bluemel <thomas@reactsoft.com>
Mon, 8 Aug 2005 15:49:37 +0000 (15:49 +0000)
committerThomas Bluemel <thomas@reactsoft.com>
Mon, 8 Aug 2005 15:49:37 +0000 (15:49 +0000)
svn path=/trunk/; revision=17208

reactos/ntoskrnl/ob/object.c

index a2bfa7c..70adcc1 100644 (file)
@@ -347,7 +347,7 @@ ObpCaptureObjectAttributes(IN POBJECT_ATTRIBUTES ObjectAttributes  OPTIONAL,
 
     if (!NT_SUCCESS(Status))
     {
-        if (ObjectName->Buffer)
+        if (ObjectName != NULL && ObjectName->Buffer)
         {
             ExFreePool(ObjectName->Buffer);
         }