#1 2014-09-17 06:07:52

edwinsn
Member
Registered: 2010-07-02
Posts: 1,215

Need some insight on an 'Access Violation' in MainEngineList()

Hi Arnaud,

I got the following error report (and that's all I have now), from the stack traces the error is deep in SynSQLite3Static, not sure what's happening, any thoughts ?

operating system   : Windows 7 x64 Service Pack 1 build 7601
system language    : English
system up time     : 5 hours 49 minutes
program up time    : 1 minute 39 seconds
processors         : 4x Intel(R) Core(TM) i3 CPU M 370 @ 2.40GHz
physical memory    : 4355/7990 MB (free/total)
free disk space    : (C:) 254.14 GB
display mode       : 1600x900, 32 bit
process id         : $32ac
allocated memory   : 78.25 MB
largest free block : 1.07 GB
compiled with      : Delphi XE4
madExcept version  : 4.0.10
callstack crc      : $e9cb975d, $f3a157ef, $83781afb
exception number   : 1
exception class    : EAccessViolation
exception message  : Access violation at address 0040895E in module 'MyProgram.exe'. Read of address 00000040.

thread $3a88 (TOmniThread):
0040895e MyProgram.exe System             191 TObject.Free
00409cfe MyProgram.exe System             191 @HandleFinallyInternal
7707b80d ntdll.dll                            RtlUnwind
7703012e ntdll.dll                            KiUserExceptionDispatcher
00409c86 MyProgram.exe System             191 @HandleFinally
7707b80d ntdll.dll                            RtlUnwind
7703012e ntdll.dll                            KiUserExceptionDispatcher
006da8a0 MyProgram.exe SynSQLite3Static  1379 sqlite3_value_numeric_type
006d3580 MyProgram.exe SynSQLite3Static  1379 sqlite3_result_value
006d36a6 MyProgram.exe SynSQLite3Static  1379 sqlite3_step
006b33bf MyProgram.exe SynSQLite3        4436 TSQLRequest.Step
006b2881 MyProgram.exe SynSQLite3        4175 TSQLRequest.Execute
009f8102 MyProgram.exe mORMotSQLite3     1053 TSQLRestServerDB.MainEngineList
007de723 MyProgram.exe mORMot           28783 TSQLRestServer.EngineList
007d09ec MyProgram.exe mORMot           24295 TSQLRest.ExecuteList
007cee34 MyProgram.exe mORMot           23667 TSQLRest.MultiFieldValues
007ceec8 MyProgram.exe mORMot           23673 TSQLRest.MultiFieldValues

Delphi XE4 Pro on Windows 7 64bit.
Lazarus trunk built with fpcupdelux on Windows with cross-compile for Linux 64bit.

Offline

#2 2014-09-17 06:18:49

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,207
Website

Re: Need some insight on an 'Access Violation' in MainEngineList()

Are you using the latest source and .obj files?

What is the SQL tree request?

What is your code like?
Are you using multi threading?

Offline

#3 2014-09-17 08:39:35

edwinsn
Member
Registered: 2010-07-02
Posts: 1,215

Re: Need some insight on an 'Access Violation' in MainEngineList()

Arnaud, Thanks for the help, this is the first time I got this error from a user, I guess it happens very rare.

I'm using SVN 574, yes, it's multi-threading program. What "SQL tree" do you mean? The SQL being executed is a simple "SELECT" statement.


Delphi XE4 Pro on Windows 7 64bit.
Lazarus trunk built with fpcupdelux on Windows with cross-compile for Linux 64bit.

Offline

#4 2014-09-17 12:53:14

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,207
Website

Re: Need some insight on an 'Access Violation' in MainEngineList()

I do not know what to say... sad

If I were you, I would enable mORMot logging and also includes the .map/.mab file corresponding to the .exe (or even better embedd the .map into the .exe).
Then you would have much more information than what you got here (SQL statement with params, context, etc...).
Ensure you set the the log Family.PerThreadLog := ptIdentifiedInOnFile (to identify each thread for the LogView tool), and set file rotation, if needed.

Offline

#5 2014-09-17 17:17:49

edwinsn
Member
Registered: 2010-07-02
Posts: 1,215

Re: Need some insight on an 'Access Violation' in MainEngineList()

Thanks for the suggestion , ab. I'll investigate into it.


Delphi XE4 Pro on Windows 7 64bit.
Lazarus trunk built with fpcupdelux on Windows with cross-compile for Linux 64bit.

Offline

#6 2014-09-17 22:06:39

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,207
Website

Re: Need some insight on an 'Access Violation' in MainEngineList()

Sounds like if the main server was free while a thread was still running some process...

Offline

#7 2014-09-18 05:54:13

edwinsn
Member
Registered: 2010-07-02
Posts: 1,215

Re: Need some insight on an 'Access Violation' in MainEngineList()

ab wrote:

Sounds like if the main server was free while a thread was still running some process...

This is a very useful hint!


Delphi XE4 Pro on Windows 7 64bit.
Lazarus trunk built with fpcupdelux on Windows with cross-compile for Linux 64bit.

Offline

#8 2014-09-18 16:17:22

edwinsn
Member
Registered: 2010-07-02
Posts: 1,215

Re: Need some insight on an 'Access Violation' in MainEngineList()

edwinsn wrote:
ab wrote:

Sounds like if the main server was free while a thread was still running some process...

This is a very useful hint!

ab, just to confirm that's the case smile Thanks!


Delphi XE4 Pro on Windows 7 64bit.
Lazarus trunk built with fpcupdelux on Windows with cross-compile for Linux 64bit.

Offline

Board footer

Powered by FluxBB