farshadmohajeri / extpascal

Automatically exported from code.google.com/p/extpascal
49 stars 28 forks source link

"Session expired or lost" bug #38

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When I open a browser,after some time,the session is time out.
if operate again,it will report:

Session expired or lost.
A new session will be created now.

the session will change to the Home procedure,In the Home procedure,
ask the user to Login,after the user login,the browser will report the 
error again:

Session expired or lost.
A new session will be created now.

because the TExtThread.RequiresReload is true,so it will report expired 
again.

I think the RequiresReload should be public,it can be modify by the 
application.

Please check it.

- ExtPascal: rev.609
- ExtJS: v.3.0
- Compiler: Delphi 7
- OSes: WindowsXP + IE7
- WebServer: Apache2
- Mode: FCGI

Original issue reported on code.google.com by luoca...@gmail.com on 25 Jan 2010 at 3:40

GoogleCodeExporter commented 9 years ago
The reason is the timeout page thread diff the Home page thread.

On a same page browser session,if you view some pages,ExtPascal will create 
many 
thread.If one page timeout,it will change to Home method,after the Home method 
run,its thread's RequiresReload := false;and return to the timeout page 
again,but 
the current timeout page thread's RequiresReload := true,still true now,so it 
will 
continue to report timeout.

Original comment by luoca...@gmail.com on 26 Feb 2010 at 9:13

GoogleCodeExporter commented 9 years ago
FCGIApp.pas
move the RequiresReload declare from TExtThread(ExtPascal.pas) to TFCGIThread.
and set public.
    RequiresReload : boolean;

on the function SetCurrentFCGIThread,reset the RequiresReload.

function TFCGIThread.SetCurrentFCGIThread : boolean;
      CurrentFCGIThread.NewThread := false;
//add the line
      CurrentFCGIThread.RequiresReload := false;
//
      CurrentFCGIThread.FResponseHeader := '';

I tested,this will work ok.
Please check.

Original comment by luoca...@gmail.com on 2 Mar 2010 at 1:23

GoogleCodeExporter commented 9 years ago

Original comment by wanderla...@gmail.com on 17 May 2010 at 2:31

GoogleCodeExporter commented 9 years ago
Fixed in r.731

Original comment by wanderla...@gmail.com on 27 May 2010 at 6:29