mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-21 21:04:32 -04:00
Fix deep search compiling on 32bit time_t targets
This commit is contained in:
parent
2bb24075c4
commit
945775e9f5
2 changed files with 4 additions and 1 deletions
|
@ -264,7 +264,8 @@ private:
|
||||||
static std::string timetToXapianDate(const rstime_t& time)
|
static std::string timetToXapianDate(const rstime_t& time)
|
||||||
{
|
{
|
||||||
char date[] = "YYYYMMDD\0";
|
char date[] = "YYYYMMDD\0";
|
||||||
std::strftime(date, 9, "%Y%m%d", std::gmtime(&time));
|
time_t tTime = static_cast<time_t>(time);
|
||||||
|
std::strftime(date, 9, "%Y%m%d", std::gmtime(&tTime));
|
||||||
return date;
|
return date;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -5140,11 +5140,13 @@ TurtleRequestId RsGxsNetService::turtleSearchRequest(const std::string& match_st
|
||||||
return mGxsNetTunnel->turtleSearchRequest(match_string,this) ;
|
return mGxsNetTunnel->turtleSearchRequest(match_string,this) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef RS_DEEP_SEARCH
|
||||||
static bool termSearch(const std::string& src, const std::string& substring)
|
static bool termSearch(const std::string& src, const std::string& substring)
|
||||||
{
|
{
|
||||||
/* always ignore case */
|
/* always ignore case */
|
||||||
return src.end() != std::search( src.begin(), src.end(), substring.begin(), substring.end(), RsRegularExpression::CompareCharIC() );
|
return src.end() != std::search( src.begin(), src.end(), substring.begin(), substring.end(), RsRegularExpression::CompareCharIC() );
|
||||||
}
|
}
|
||||||
|
#endif // ndef RS_DEEP_SEARCH
|
||||||
|
|
||||||
bool RsGxsNetService::retrieveDistantSearchResults(TurtleRequestId req,std::map<RsGxsGroupId,RsGxsGroupSummary>& group_infos)
|
bool RsGxsNetService::retrieveDistantSearchResults(TurtleRequestId req,std::map<RsGxsGroupId,RsGxsGroupSummary>& group_infos)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue