I really did search for this, but didn't find an answer. I'm moving from CF
4 to 4.5, and have turned on "Automatic Read Locking" in all scopes. Now
I'm going through to see what's broken as a result. Note that I'm trying to
maintain compatibility with 4.0 as much as possible.
I found a section of code like this
<cflock name="#Cookie.CFID##Cookie.CFTOKEN#" type="exclusive" timeout="30"
throwontimeout="yes">
... some other code, but no cflocks of any kind...
<cfset session.userid = "blah">
</cflock>
which, when run, generates the following error:
Symbol session.userid is in a scope that contains data shared across threads
and cannot be accessed without an active lock
Now, if I do this:
<cflock name="#Cookie.CFID##Cookie.CFTOKEN#" type="exclusive" timeout="30"
throwontimeout="yes">
... some other code, but no cflocks of any kind...
<cflock scope="session" type="exclusive" timeout="5">
<cfset session.userid = "blah">
</cflock>
</cflock>
it works fine, but of course CF 4 won't accept that.
Is there any way to make CF understand that the first lock is protecting
that session scope?
------------------------------------
Martin Herbener
Kentucky Department of Education
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists