Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ MT-multithreading and servers » Probable bug in Skylark and sessions
Probable bug in Skylark and sessions [message #40339] Mon, 22 July 2013 12:09
mdelfede is currently offline  mdelfede
Messages: 1307
Registered: September 2007
Ultimate Contributor
Hi,

I started to use persistent sessions in my app, with default parameters (just changed cookie name and expiration time, so it should go to filesystem), and the app crashed inside Http::Dispatch() with invalid memory access:

				if(SQL.IsOpen())
					SQL.Begin();
				LoadSession();
				session_dirty = false;
				if(post && !bd.post_raw) {
					String id = Nvl((*this)["__post_identity__"], (*this)["__js_identity__"]);
					if(id != (*this)[".__identity__"])
						throw AuthExc("identity error");
				}
				lang = Nvl(Int(".__lang__"), LNG_ENGLISH);
				Upp::SetLanguage(lang);
				var.GetAdd(".__lang__") = lang;
				var.GetAdd(".language") = ToLower(LNGAsText(lang));
				handlerid = bd.id;
				LDUMP(handlerid);
				bd.handler(*this);
				if(session_dirty)
					SaveSession();
----CRASH HERE--->		if(SQL.IsOpen())
					SQL.Commit();


Commenting out this (and the former one, to be sure...) the app runs well. It seems that it tries to access some uninitializad data inside SQL.
The weird stuff is that tracing it, on FIRST call (the one at start of this code fragment) it creates a static, empty Sql variabile, NOT going to threading code; on second one (the crashing one) it goes through threading part.
I compiled in MT, but i'm running in debug mode, so it should be single threaded... I guess.

Previous Topic: Skylark and SCGI
Next Topic: How to pass vector/array of structs to witz?
Goto Forum:
  


Current Time: Fri Mar 29 08:03:24 CET 2024

Total time taken to generate the page: 0.01178 seconds