diff --git a/src/HTTPSock.cpp b/src/HTTPSock.cpp index e101971f..da196e47 100644 --- a/src/HTTPSock.cpp +++ b/src/HTTPSock.cpp @@ -225,6 +225,9 @@ void CHTTPSock::GetPage() { DEBUG("Expected prefix: " << m_sURIPrefix); DEBUG("Requested path: " << m_sURI); Redirect("/"); + } else if (m_sURI.empty()) { + // This can happen if prefix was /foo, and the requested page is /foo + Redirect("/"); } else { OnPageRequest(m_sURI); }