Custom Query (3933 matches)
Results (442 - 444 of 3933)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #1393 | Fixed | Script crashes with error reported in EventLog.au3 at line 475 | ||
| Description |
My Usage: Script uses EventLog.au3 to access remote event logs. The task is to simply open, read all available records, and close the log. Problem: Shortly after starting, script crashes reporting an error at line 475 of EventLog.au3 involving use of a subscript with a non-array variable. This code assumes _SecurityLookupAccountSid only returns an array. In fact, _SecurityLookupAccountSid can return zero. Initial Solution: Change the code in EventLog.au3 line 475 to test for an array before using it. Below are the two functions involved in the problem. The first is _EventLogDecodeUserName from EventLog.au3 - where the error is. The second is _SecurityLookupAccountSid from Security.au3 for reference only. ######################################################
###################################################### Note that _EventLogDecodeUserName assumes _SecurityLookupAccountSid will always returns an array. ; #INTERNAL_USE_ONLY# =========================================================================================================== ; Name...........: _EventLogDecodeUserName ; Description ...: Decodes the user name from an event log record ; Syntax.........: _EventLogDecodeUserName($tEventLog) ; Parameters ....: $tEventLog - tagEVENTLOGRECORD structure ; Return values .: Success - User name ; Author ........: Paul Campbell (PaulIA) ; Modified.......: Gary Frost (gafrost) ; Remarks .......: This function is used internally ; Related .......: ; Link ..........: ; Example .......: ; =============================================================================================================================== Func _EventLogDecodeUserName($tEventLog)
; Return $aAcctInfo[1] [original line 475] Revised 5-Jan-2010 - jrw If IsArray($aAcctInfo) Then Return $aAcctInfo[1] Return '' EndFunc ;==>_EventLogDecodeUserName ######################################################
###################################################### Note that _SecurityLookupAccountSid MAY NOT return an array.
; #FUNCTION# ==================================================================================================================== ; Name...........: _SecurityLookupAccountSid ; Description ...: Retrieves the name of the account for a SID ; Syntax.........: _SecurityLookupAccountSid($vSID) ; Parameters ....: $vSID - Either a binary SID or a string SID ; Return values .: Success - Array with the following format: ; |$aAcct[0] - Account name ; |$aAcct[1] - Domain name ; |$aAcct[2] - SID type, which can be one of the following values: ; | 1 - Indicates a user SID ; | 2 - Indicates a group SID ; | 3 - Indicates a domain SID ; | 4 - Indicates an alias SID ; | 5 - Indicates a SID for a well-known group ; | 6 - Indicates a SID for a deleted account ; | 7 - Indicates an invalid SID ; | 8 - Indicates an unknown SID type ; | 9 - Indicates a SID for a computer ; Failure - 0 ; Author ........: Paul Campbell (PaulIA) ; Modified.......: ; Remarks .......: ; Related .......: _SecurityLookupAccountName, _SecurityGetAccountSid ; Link ..........: @@MsdnLink@@ LookupAccountSid ; Example .......: ; =============================================================================================================================== Func _SecurityLookupAccountSid($vSID)
EndFunc ;==>_SecurityLookupAccountSid |
|||
| #1395 | Fixed | DLLCallbacks on Exit | ||
| Description |
I wish it would be possible to have DLLCllbacks persist longer in the destruction chain on script termination. At least it would be great to have them alive when objects are released. This would allow to implement the 'hooking into IDispatch' directly in AutoIt without errors and without CoCreateInstance. Therefore an Object::release-dllcallback is needed and up to now AutoIt crashes and fails to exit when there are such objects on termination. http://www.autoitscript.com/forum/index.php?showtopic=107678&view=findpost&p=759950 You can come around this by freeing the Object-Variable manually, but you can't do that on an AutoIt-Error like "Array out of bounds" or any other error on which Autoit is terminating without calling the ExitFuncs. I don't know if this change is possible, but if it is this would be a great enhancement in favour of supporting objects. PS: I think, this is related to tracid #1319 |
|||
| #1396 | Fixed | DllCallbackGetPtr crashes on invalid handle | ||
| Description |
Not much to say. DllCallbackGetPtr() produces an access violation on bad handle. DllCallbackGetPtr(0) |
|||
