View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0006696 | JEDI VCL | 00 JVCL Components | public | 2020-06-04 07:01 | 2020-08-09 10:44 |
Reporter | thayalan | Assigned To | |||
Priority | high | Severity | major | Reproducibility | always |
Status | new | Resolution | open | ||
Platform | x64 | OS | Windows | OS Version | 2019 |
Product Version | 3.48 | ||||
Target Version | Fixed in Version | ||||
Summary | 0006696: Incorrect pointer arithmatic in JvNTEventLog.pas | ||||
Description | JvNTEventLog.pas uses pointer arithmetic to access the variables in a event record. It is currently coded, in multiple places as: Result := PChar(FCurrentRecord) + SizeOf(TEventLogRecord); // Line 552. This does not work, as the PChar is now multibyte. As a result, even though SizeOf(TEventLogRecord) = 56 ($38), but the above adds $70 every time, and leads to wrong string values & SIDs. | ||||
Steps To Reproduce | Just run the sample NtEventLog Demo and check the output for Source, UserName etc. | ||||
Additional Information | This happens in multiple places. In Version 3.49 @ lines 552, 559, 582 SOLUTION seems straight forward: e.g. in line 552: Result := PChar(NativeInt(FCurrentRecord) + SizeOf(TEventLogRecord)); I have attached two screen shots of the demo program with and without the solution applied. (See the original file does not show username, computer name & shows incorrect source. Thank you for all your work on JEDI. | ||||
Tags | No tags attached. | ||||