Rename LOG_LEVEL_GPC to LOG_LEVEL_REQUEST
authorFabian Keil <fk@fabiankeil.de>
Fri, 29 May 2020 16:57:28 +0000 (18:57 +0200)
committerFabian Keil <fk@fabiankeil.de>
Mon, 1 Jun 2020 08:11:30 +0000 (10:11 +0200)
Only the shadow knows what "GPC" is supposed to stand for.

errlog.c
errlog.h
jcc.c

index a085227..05a2c82 100644 (file)
--- a/errlog.c
+++ b/errlog.c
@@ -601,7 +601,7 @@ static inline const char *get_log_level_string(int loglevel)
       case LOG_LEVEL_FATAL:
          log_level_string = "Fatal error";
          break;
-      case LOG_LEVEL_GPC:
+      case LOG_LEVEL_REQUEST:
          log_level_string = "Request";
          break;
       case LOG_LEVEL_CONNECT:
@@ -684,7 +684,7 @@ void log_error(int loglevel, const char *fmt, ...)
     * the taskbar icon animate.  (There is an option to disable
     * this but checking that is handled inside LogShowActivity()).
     */
-   if ((loglevel == LOG_LEVEL_GPC) || (loglevel == LOG_LEVEL_CRUNCH))
+   if ((loglevel == LOG_LEVEL_REQUEST) || (loglevel == LOG_LEVEL_CRUNCH))
    {
       LogShowActivity();
    }
index 0a805f4..5bfc16a 100644 (file)
--- a/errlog.h
+++ b/errlog.h
@@ -37,8 +37,7 @@
 
 /* Debug level for errors */
 
-/* XXX: Should be renamed. */
-#define LOG_LEVEL_GPC        0x0001
+#define LOG_LEVEL_REQUEST    0x0001
 #define LOG_LEVEL_CONNECT    0x0002
 #define LOG_LEVEL_IO         0x0004
 #define LOG_LEVEL_HEADER     0x0008
diff --git a/jcc.c b/jcc.c
index 898618a..33603c0 100644 (file)
--- a/jcc.c
+++ b/jcc.c
@@ -2397,7 +2397,7 @@ static jb_err process_encrypted_request(struct client_state *csp)
 
    log_error(LOG_LEVEL_HEADER, "Encrypted request processed");
    log_applied_actions(csp->action);
-   log_error(LOG_LEVEL_GPC, "https://%s%s", csp->http->hostport,
+   log_error(LOG_LEVEL_REQUEST, "https://%s%s", csp->http->hostport,
       csp->http->path);
 
    return err;
@@ -3675,7 +3675,7 @@ static void chat(struct client_state *csp)
    if (!client_use_ssl(csp))
 #endif
    {
-      log_error(LOG_LEVEL_GPC, "%s%s", http->hostport, http->path);
+      log_error(LOG_LEVEL_REQUEST, "%s%s", http->hostport, http->path);
    }
    if (fwd->forward_host)
    {