From: Michael R Sweet Date: Fri, 16 May 2025 22:32:07 +0000 (-0400) Subject: Redirect to home page on logout. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c0ea9cba0ea73ca61671fd9fab026fa3ae7a4029;p=thirdparty%2Fcups.git Redirect to home page on logout. --- diff --git a/cgi-bin/home.c b/cgi-bin/home.c index 22e8819f85..84c8d7e28a 100644 --- a/cgi-bin/home.c +++ b/cgi-bin/home.c @@ -119,6 +119,8 @@ do_login(void) goto done; } + fprintf(stderr, "DEBUG2: do_login: oauth_uri=\"%s\"\n", oauth_uri); + // Get the redirect URL... if (!strcmp(server_name, "localhost")) snprintf(redirect_uri, sizeof(redirect_uri), "http://127.0.0.1:%s/", server_port); @@ -181,7 +183,7 @@ do_logout(void) cgiSetCookie("CUPS_BEARER", "", /*path*/NULL, /*domain*/NULL, time(NULL) - 1, /*secure*/0); // Redirect back to the referrer... - do_redirect(getenv("HTTP_REFERER")); + do_redirect("/"); }