diff --git a/src/kits/network/libnetapi/GopherRequest.cpp b/src/kits/network/libnetapi/GopherRequest.cpp index 13193de85b..9f5c3b3ed5 100644 --- a/src/kits/network/libnetapi/GopherRequest.cpp +++ b/src/kits/network/libnetapi/GopherRequest.cpp @@ -316,6 +316,16 @@ BGopherRequest::_ProtocolLoop() // continue parsing the error text anyway } } + // special case for buggy(?) Gophernicus/1.5 + static const char *buggy = "Error: File or directory not found!"; + if (fInputBuffer.Size() > strlen(buggy) + && !memcmp(fInputBuffer.Data(), buggy, strlen(buggy))) { + fItemType = GOPHER_TYPE_DIRECTORY; + readError = B_RESOURCE_NOT_FOUND; + // continue parsing the error text anyway + // but it won't look good + } + // now we probably have correct data dataValidated = true;