[NTOSKRNL]
authorAmine Khaldi <amine.khaldi@reactos.org>
Mon, 7 Oct 2013 11:50:09 +0000 (11:50 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Mon, 7 Oct 2013 11:50:09 +0000 (11:50 +0000)
* Fix an out-of-bounds access. CID 731663.
CORE-6681

svn path=/trunk/; revision=60571

reactos/ntoskrnl/ob/obname.c

index 0744da0..7f6274d 100644 (file)
@@ -1198,9 +1198,7 @@ ObQueryNameString(IN PVOID Object,
                     ObjectName = (PWCH)((ULONG_PTR)ObjectName -
                                                    sizeof(L"...") +
                                                    sizeof(UNICODE_NULL));
-                    RtlCopyMemory(ObjectName,
-                                  L"...",
-                                  sizeof(L"...") + sizeof(UNICODE_NULL));
+                    RtlCopyMemory(ObjectName, L"...", sizeof(L"..."));
                     break;
                 }
             }