This commit is contained in:
RedKale
2016-03-29 19:27:14 +08:00
parent 5a287685af
commit 1ef38b6620

View File

@@ -529,7 +529,7 @@ public class HttpResponse extends Response<HttpContext, HttpRequest> {
domain = "Domain=" + domain + "; ";
}
String path = defcookie == null ? null : defcookie.getPath();
if (path == null) path = "/";
if (path == null || path.isEmpty()) path = "/";
if (request.newsessionid.isEmpty()) {
buffer.put(("Set-Cookie: " + HttpRequest.SESSIONID_NAME + "=; " + domain + "Path=" + path + "; Max-Age=0; HttpOnly\r\n").getBytes());
} else {