mirror of
https://gitea.psi.ch/ELOG/elog.git
synced 2026-09-08 17:13:56 +00:00
Fixed wrong cookies which caused problems with Chrome
SVN revision: 2137
This commit is contained in:
parent
4517ec81b7
commit
21a67ec16e
19
src/elogd.c
19
src/elogd.c
@ -7151,22 +7151,9 @@ void show_http_header(LOGBOOK * lbs, BOOL expires, char *cookie)
|
|||||||
else
|
else
|
||||||
rsprintf("Content-Type: text/html;charset=%s\r\n", DEFAULT_HTTP_CHARSET);
|
rsprintf("Content-Type: text/html;charset=%s\r\n", DEFAULT_HTTP_CHARSET);
|
||||||
|
|
||||||
if (cookie && cookie[0]) {
|
if (cookie && cookie[0])
|
||||||
|
|
||||||
set_cookie(lbs, cookie, NULL, FALSE, "99999"); /* ten years by default */
|
set_cookie(lbs, cookie, NULL, FALSE, "99999"); /* ten years by default */
|
||||||
|
|
||||||
if (getcfg(lbs->name, "URL", str, sizeof(str))) {
|
|
||||||
extract_path(str);
|
|
||||||
url_encode(str, sizeof(str));
|
|
||||||
if (str[0])
|
|
||||||
rsprintf(" path=/%s/%s;", str, lbs->name_enc);
|
|
||||||
else
|
|
||||||
rsprintf(" path=/%s;", lbs->name_enc);
|
|
||||||
} else
|
|
||||||
rsprintf(" path=/%s;", lbs->name_enc);
|
|
||||||
rsprintf("\r\n");
|
|
||||||
}
|
|
||||||
|
|
||||||
if (use_keepalive) {
|
if (use_keepalive) {
|
||||||
rsprintf("Connection: Keep-Alive\r\n");
|
rsprintf("Connection: Keep-Alive\r\n");
|
||||||
rsprintf("Keep-Alive: timeout=60, max=10\r\n");
|
rsprintf("Keep-Alive: timeout=60, max=10\r\n");
|
||||||
@ -27465,6 +27452,10 @@ void server_loop(void)
|
|||||||
if (image_magick_exist)
|
if (image_magick_exist)
|
||||||
eprintf("ImageMagick detected\n");
|
eprintf("ImageMagick detected\n");
|
||||||
|
|
||||||
|
/* check for keepalive */
|
||||||
|
if (!use_keepalive)
|
||||||
|
eprintf("Keep-alive disabled\n");
|
||||||
|
|
||||||
/* build logbook indices */
|
/* build logbook indices */
|
||||||
if (!verbose && !running_as_daemon)
|
if (!verbose && !running_as_daemon)
|
||||||
eprintf("Indexing logbooks ... ");
|
eprintf("Indexing logbooks ... ");
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user