Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 1.2.1, 1.3.7
-
Fix Version/s: None
-
Component/s: Controllers
-
Labels:
-
Environment:Grails 1.2.1 ~ Grails 1.3.7
Description
I found that the withForm did not work in my project sometimes, then I read the resource code of Grails, I found that there was a bug in the file WithFormMethod.groovy,
TokenResponseHandler withForm(HttpServletRequest request, Closure callable) {
TokenResponseHandler handler
if (isTokenValid(request))
......
}
the isTokenValid(request) and resetToken(request) are not in the same synchronized block
change into:
TokenResponseHandler withForm(HttpServletRequest request, Closure callable) {
TokenResponseHandler handler
synchronized(this){
if (isTokenValid(request)) { resetToken(request) handler = new ValidResponseHandler(callable?.call()) }
......
}
and remove the "synchronized" in method isTokenValid and resetToken
Activity
Burt Beckwith
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Workflow | jira [ 39632 ] | Grails [ 41469 ] |
Burt Beckwith
made changes -
| Workflow | Grails [ 41469 ] | Copy of Grails [ 48895 ] |
Burt Beckwith
made changes -
| Workflow | Copy of Grails [ 48895 ] | Grails [ 56305 ] |
Burt Beckwith
made changes -
| Workflow | Grails [ 56305 ] | Grails2 [ 63840 ] |
Burt Beckwith
made changes -
| Workflow | Grails2 [ 63840 ] | jira [ 75733 ] |
Burt Beckwith
made changes -
| Workflow | jira [ 75733 ] | Grails2 [ 84482 ] |
Peter Ledbrook
made changes -
| Last Reviewed | 01/Jan/10 |
Peter Ledbrook
made changes -
| Workflow | Grails2 [ 84482 ] | jira [ 92925 ] |
Peter Ledbrook
made changes -
| Workflow | jira [ 92925 ] | Grails2 [ 101095 ] |