Merge branch 'master' of ssh://git.citadel.org/appl/gitroot/citadel
authorWilfried Goesgens <dothebart@citadel.org>
Mon, 30 Jan 2012 23:53:13 +0000 (00:53 +0100)
committerWilfried Goesgens <dothebart@citadel.org>
Mon, 30 Jan 2012 23:53:13 +0000 (00:53 +0100)
webcit/context_loop.c
webcit/gettext.c
webcit/webcit.c

index fb59144..bcab115 100644 (file)
@@ -335,7 +335,7 @@ int ReadHttpSubject(ParsedHttpHdrs *Hdr, StrBuf *Line, StrBuf *Buf)
        }
        else {
                Hdr->HR.DontNeedAuth = 1; /* Flat request? show him the login screen... */
-               StrBuf *NewLine = NewStrBufPlain(HKEY("GET /readfwd?go="));
+               StrBuf *NewLine = NewStrBufPlain(HKEY("GET /do_template?template=login"));
                StrBufUrlescAppend(NewLine, Buf, NULL);
                StrBufAppendBufPlain(NewLine, HKEY(" HTTP/1.0"), 0);
                syslog(LOG_DEBUG, "Replacing with: %s", ChrPtr(NewLine));
index f1b2f8a..6a5c3c8 100644 (file)
@@ -248,6 +248,7 @@ void set_selected_language(const char *lang) {
        for (i = 0; i<nLocalesLoaded; ++i) {
                if (!strcasecmp(lang, AvailLangLoaded[i])) {
                        WC->selected_language = i;
+                       break;
                }
        }
 #endif
index 944b457..8a96a13 100644 (file)
@@ -245,6 +245,7 @@ void http_redirect(const char *whichpage) {
        hprintf("Location: %s\r\n", whichpage);
        hprintf("URI: %s\r\n", whichpage);
        hprintf("Content-type: text/html; charset=utf-8\r\n");
+       stuff_to_cookie(0);
        begin_burst();
        wc_printf("<html><body>");
        wc_printf("Go <a href=\"%s\">here</A>.", whichpage);