Title:
Bug 87084:[maestrofjp] I've confirmed there is a bug in ACF9 having to do with StructKeyDelete() and structs shared by reference
| View in TrackerStatus/Resolution/Reason: Closed/Withdrawn/
Reporter/Name(from Bugbase): Peter Farrell / Peter Farrell (MaestroFJP)
Created: 08/29/2011
Components: Language, Datastructure
Versions: 9.0.1
Failure Type:
Found In Build/Fixed In Build: 0000 /
Priority/Frequency: Major / Some users will encounter
Locale/System: English / Platforms All
Vote Count: 36
Problem:
[maestrofjp] I've confirmed there is a bug in ACF9 having to do with StructKeyDelete() and structs shared by reference. Below is a download that Doug Smith at Dave Ramsey put together to prove the issue. This issue does not exist on ACF8, Railo or OpenBD. It happens on ACF9 and 9.01.http://dl.dropbox.com/u/12411108/machii_19_reload_bug_test.zip> FROM: http://trac.mach-ii.com/machii/ticket/795>> The problem always happens in a loop similar to this:> <cfloop collection="#variables.logAdapters#" item="key">> <cfset variables.logAdapters[key].info(channel, arguments.message) />> </cfloop>>> The key exists in the loop, but when the call to "...info(...)" is attempted, the key is no longer in the logAdapters struct.I can confirm that this is NOT a race issue. It appears that calling StructKeyDelete() does not get the struct shared by reference updated therefore looping over that struct later on in the code causes the loop to think a key is available when it is not. Is there a Java Weak Hash Map or something going on behind the scenes? This type of error sounds like weak hash map issue in Java if I was going to guess.
Method:
Use this test case to illustrate the issue.Element 690A54784FACC6DD06E3D45D396E0BB6 is undefined in a CFML structure referenced as part of an expression.
Result:
Element 690A54784FACC6DD06E3D45D396E0BB6 is undefined in a CFML structure referenced as part of an expression.
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 3044009
External Customer Info:
External Company:
External Customer Name: Peter Farrell
External Customer Email: 49ED14CD43A7342099201674
External Test Config: 08/29/2011
Attachments:
Comments: