sql+="AND (tblIdentity.LocalMessageTrust>=(SELECT OptionValue FROM tblOption WHERE Option='MinLocalMessageTrust') OR (tblIdentity.LocalMessageTrust IS NULL AND (tblIdentity.PeerMessageTrust IS NULL OR tblIdentity.PeerMessageTrust>=(SELECT OptionValue FROM tblOption WHERE Option='MinPeerMessageTrust')))) ";\r
}\r
sql+="AND tblIdentity.Name <> '' ";\r
+ // sort by day descending - in case there is a bunch of messages on a day that keep timing out, we will eventually get to the next day and hopefully find messages there\r
+ sql+="ORDER BY tblMessageRequests.Day DESC ";\r
sql+=";";\r
\r
SQLite3DB::Statement st=m_db->Prepare(sql);\r
message["Identifier"]=m_fcpuniquename+"|"+requestid+"|"+parts[0]+"|"+parts[1]+"|"+parts[2]+"|"+message["URI"];\r
message["ReturnType"]="direct";\r
message["MaxSize"]="1000000"; // 1 MB\r
- message["MaxRetries"]="-1"; // use new ULPR since we are fairly sure message exists since the author says it does\r
+ message["MaxRetries"]="-1"; // use ULPR since we are fairly sure message exists since the author says it does\r
\r
m_fcp->SendMessage(message);\r
\r