Browse Source

Don't propagate 4xx error statuses from proxied media.

grunfink 1 month ago
parent
commit
52adad8882
1 changed files with 3 additions and 0 deletions
  1. 3 0
      html.c

+ 3 - 0
html.c

@@ -5328,6 +5328,9 @@ int html_get_handler(const xs_dict *req, const char *q_path,
                     }
                     }
                 }
                 }
             }
             }
+            else
+            if (status >= 400 && status <= 499)
+                status = HTTP_STATUS_NOT_FOUND;
 
 
             snac_debug(&snac, 1, xs_fmt("Proxy for %s %d", url, status));
             snac_debug(&snac, 1, xs_fmt("Proxy for %s %d", url, status));
         }
         }