+ StrBufAppendPrintf(WCC->HBuf, "Set-cookie: webcit=");
+ snprintf(buf, sizeof(buf), "%d", WCC->wc_session);
+ StrBufHexescAppend(WCC->HBuf, NULL, buf);
+ StrBufHexescAppend(WCC->HBuf, NULL, "|");
+ StrBufHexescAppend(WCC->HBuf, WCC->wc_username, NULL);
+ StrBufHexescAppend(WCC->HBuf, NULL, "|");
+ StrBufHexescAppend(WCC->HBuf, WCC->wc_password, NULL);
+ StrBufHexescAppend(WCC->HBuf, NULL, "|");
+ StrBufHexescAppend(WCC->HBuf, WCC->CurRoom.name, NULL);
+ StrBufHexescAppend(WCC->HBuf, NULL, "|");
+ StrBufHexescAppend(WCC->HBuf, NULL, get_selected_language());
+ StrBufHexescAppend(WCC->HBuf, NULL, "|");
+
+ if (server_cookie != NULL) {
+ StrBufAppendPrintf(WCC->HBuf,
+ ";path=/ \r\n%s\r\n",
+ server_cookie);
+ }
+ else {
+ StrBufAppendBufPlain(WCC->HBuf,
+ HKEY("; path=/\r\n"), 0);