Author: khornicek
Date: Fri Oct 31 22:39:19 2014
New Revision: 65162
URL:
http://svn.reactos.org/svn/reactos?rev=65162&view=rev
Log:
[EVENTLOG]
- fix a possible null dereference
Modified:
trunk/reactos/base/services/eventlog/rpc.c
Modified: trunk/reactos/base/services/eventlog/rpc.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/services/eventlog/rpc…
==============================================================================
--- trunk/reactos/base/services/eventlog/rpc.c [iso-8859-1] (original)
+++ trunk/reactos/base/services/eventlog/rpc.c [iso-8859-1] Fri Oct 31 22:39:19 2014
@@ -118,6 +118,14 @@
if (lpLogHandle->LogFile == NULL)
{
lpLogHandle->LogFile = LogfListItemByName(L"Application");
+
+ if (lpLogHandle->LogFile == NULL)
+ {
+ DPRINT1("Application log is missing!\n");
+ Status = STATUS_UNSUCCESSFUL;
+ goto Done;
+ }
+
lpLogHandle->CurrentRecord =
LogfGetOldestRecord(lpLogHandle->LogFile);
}
}