Get recoll to compile with clang (on freebsd) and eliminate warnings. You can no build recoll with make CXX=clang LINK=clang

This commit is contained in:
Jean-Francois Dockes
2012-05-20 17:35:03 +02:00
parent cbe7fd21cb
commit f34994d882
13 changed files with 42 additions and 31 deletions
+7 -7
View File
@@ -80,7 +80,7 @@ void Binc::MimeDocument::parseFull(int fd) const
int bsize = 0;
string bound;
MimePart::parseFull(bound, bsize);
doParseFull(bound, bsize);
// eat any trailing junk to get the correct size
char c;
@@ -109,7 +109,7 @@ void Binc::MimeDocument::parseFull(istream& s) const
int bsize = 0;
string bound;
MimePart::parseFull(bound, bsize);
doParseFull(bound, bsize);
// eat any trailing junk to get the correct size
char c;
@@ -286,7 +286,7 @@ static void parseMessageRFC822(vector<Binc::MimePart> *members,
// parsefull returns the number of bytes that need to be removed
// from the body because of the terminating boundary string.
int bsize = 0;
if (m.parseFull(toboundary, bsize))
if (m.doParseFull(toboundary, bsize))
*foundendofpart = true;
// make sure bodylength doesn't overflow
@@ -468,7 +468,7 @@ static void parseMultipart(const string &boundary,
// If parseFull returns != 0, then it encountered the multipart's
// final boundary.
int bsize = 0;
if (m.parseFull(boundary, bsize)) {
if (m.doParseFull(boundary, bsize)) {
quit = true;
*boundarysize = bsize;
}
@@ -591,10 +591,10 @@ static void parseSinglePart(const string &toboundary,
}
//------------------------------------------------------------------------
int Binc::MimePart::parseFull(const string &toboundary,
int Binc::MimePart::doParseFull(const string &toboundary,
int &boundarysize) const
{
MPFDEB((stderr, "BINC: parsefull, toboundary[%s]\n", toboundary.c_str()));
MPFDEB((stderr, "BINC: doParsefull, toboundary[%s]\n", toboundary.c_str()));
headerstartoffsetcrlf = mimeSource->getOffset();
// Parse the header of this mime part.
@@ -626,6 +626,6 @@ int Binc::MimePart::parseFull(const string &toboundary,
&eof, &foundendofpart, &bodylength);
}
MPFDEB((stderr, "BINC: parsefull ret, toboundary[%s]\n", toboundary.c_str()));
MPFDEB((stderr, "BINC: doParsefull ret, toboundary[%s]\n", toboundary.c_str()));
return (eof || foundendofpart) ? 1 : 0;
}
+3 -3
View File
@@ -72,7 +72,7 @@ void Binc::MimeDocument::parseOnlyHeader(int fd) const
nlines = 0;
nbodylines = 0;
MimePart::parseOnlyHeader("");
doParseOnlyHeader("");
}
void Binc::MimeDocument::parseOnlyHeader(istream& s) const
@@ -95,11 +95,11 @@ void Binc::MimeDocument::parseOnlyHeader(istream& s) const
nlines = 0;
nbodylines = 0;
MimePart::parseOnlyHeader("");
doParseOnlyHeader("");
}
//------------------------------------------------------------------------
int Binc::MimePart::parseOnlyHeader(const string &toboundary) const
int Binc::MimePart::doParseOnlyHeader(const string &toboundary) const
{
string name;
string content;
+2 -2
View File
@@ -114,8 +114,8 @@ namespace Binc {
virtual void clear(void) const;
const MimePart *getPart(const std::string &findpart, std::string genpart, FetchType fetchType = FetchBody) const;
virtual int parseOnlyHeader(const std::string &toboundary) const;
virtual int parseFull(const std::string &toboundary, int &boundarysize) const;
virtual int doParseOnlyHeader(const std::string &toboundary) const;
virtual int doParseFull(const std::string &toboundary, int &boundarysize) const;
MimePart(void);
virtual ~MimePart(void);