Subversion Repositories SmartDukaan

Rev

Rev 1722 | Rev 2907 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1722 Rev 2473
Line 137... Line 137...
137
                    log.info("Invalid session with user cookie : " + receivedUID);
137
                    log.info("Invalid session with user cookie : " + receivedUID);
138
					userInfo = new UserSessionInfo(receivedUID, session.getId());
138
					userInfo = new UserSessionInfo(receivedUID, session.getId());
139
					session.setAttribute(USER_INFO, userInfo);
139
					session.setAttribute(USER_INFO, userInfo);
140
				} catch (NumberFormatException nfe) {
140
				} catch (NumberFormatException nfe) {
141
					log.error("The UID cookie contains an unparseable userID");
141
					log.error("The UID cookie contains an unparseable userID");
-
 
142
					Cookie newUserCookie = new Cookie("uid", "-1"); //The value here is immaterial
-
 
143
					newUserCookie.setMaxAge(0);                     // Expire this cookie now
-
 
144
					newUserCookie.setPath("/");
-
 
145
					newUserCookie.setDomain(cookieDomain);
-
 
146
					
-
 
147
					HttpServletResponse response = ServletActionContext.getResponse();
-
 
148
					response.addCookie(newUserCookie);
-
 
149
					
-
 
150
					userInfo = new UserSessionInfo();
-
 
151
					session.setAttribute(USER_INFO, userInfo);
142
				}
152
				}
143
			}
153
			}
144
		}
154
		}
145
		else{
155
		else{
146
			userInfo = new UserSessionInfo();
156
			userInfo = new UserSessionInfo();