return crawl delete reply in json.
take out EDOCEVILREDIRECT errors.
This commit is contained in:
parent
3b929917d1
commit
2ae04cff71
@ -2262,6 +2262,15 @@ bool sendPageCrawlbot ( TcpSocket *socket , HttpRequest *hr ) {
|
||||
name = NULL;
|
||||
// no longer a delete function, we need to set "name" below
|
||||
delColl = false;//NULL;
|
||||
// john wants just a brief success reply
|
||||
char *reply = "{\"reply\":\"Successfully deleted crawl.\"}";
|
||||
return g_httpServer.sendDynamicPage( socket,
|
||||
reply,
|
||||
gbstrlen(reply),
|
||||
0, // cacheTime
|
||||
false, // POSTReply?
|
||||
"application/json"
|
||||
);
|
||||
}
|
||||
|
||||
// if name is missing default to name of first existing
|
||||
|
10
XmlDoc.cpp
10
XmlDoc.cpp
@ -8931,11 +8931,11 @@ Url **XmlDoc::getRedirUrl() {
|
||||
return &m_redirUrlPtr;
|
||||
}
|
||||
// do not allow redirects to evil-G or bing
|
||||
if ( strstr(loc->getUrl(),".google.com/") ||
|
||||
strstr(loc->getUrl(),".bing.com/") ) {
|
||||
m_redirError = EDOCEVILREDIRECT;
|
||||
return &m_redirUrlPtr;
|
||||
}
|
||||
//if ( strstr(loc->getUrl(),".google.com/") ||
|
||||
// strstr(loc->getUrl(),".bing.com/") ) {
|
||||
// m_redirError = EDOCEVILREDIRECT;
|
||||
// return &m_redirUrlPtr;
|
||||
//}
|
||||
// log a msg
|
||||
//if ( g_conf.m_logSpideredUrls )
|
||||
// logf(LOG_INFO,"build: %s redirected to %s",
|
||||
|
Loading…
x
Reference in New Issue
Block a user