extra/seamonkey: remove unneeded patch

This commit is contained in:
Kevin Mihelich 2015-03-12 11:38:23 +00:00
parent 7cc231b5c0
commit 61305df162
2 changed files with 2 additions and 127 deletions

View file

@ -1,122 +0,0 @@
# HG changeset patch
# User Steve Singer <steve@ssinger.info>
# Date 1414612994 25200
# Node ID 273bcc4d6e9b93e3a48b286b4f3f935c18176525
# Parent 33d45705a4d10668408b47cb3c13322ea7496841
Bug 1085151 - avoid char (-1) in FilterList to compile on powerpc, r=rkent, a=rkent
diff --git a/mailnews/base/search/src/nsMsgFilterList.cpp b/mailnews/base/search/src/nsMsgFilterList.cpp
--- a/mailnews/base/search/src/nsMsgFilterList.cpp
+++ b/mailnews/base/search/src/nsMsgFilterList.cpp
@@ -27,16 +27,18 @@
// unicode "%s" format string
static const char16_t unicodeFormatter[] = {
(char16_t)'%',
(char16_t)'s',
(char16_t)0,
};
+// Marker for EOF or failure during read
+#define EOF_CHAR (char) 0xFF
nsMsgFilterList::nsMsgFilterList() :
m_fileVersion(0)
{
m_loggingEnabled = false;
m_startWritingToBuffer = false;
m_temporaryList = false;
m_curFilter = nullptr;
@@ -378,21 +380,21 @@ static const unsigned int sNumFilterFile
// If we want to buffer file IO, wrap it in here.
char nsMsgFilterList::ReadChar(nsIInputStream *aStream)
{
char newChar;
uint32_t bytesRead;
nsresult rv = aStream->Read(&newChar, 1, &bytesRead);
if (NS_FAILED(rv) || !bytesRead)
- return -1;
+ return EOF_CHAR;
uint64_t bytesAvailable;
rv = aStream->Available(&bytesAvailable);
if (NS_FAILED(rv))
- return -1;
+ return EOF_CHAR;
else
{
if (m_startWritingToBuffer)
m_unparsedFilterBuffer.Append(newChar);
return newChar;
}
}
@@ -417,17 +419,17 @@ char nsMsgFilterList::LoadAttrib(nsMsgFi
char attribStr[100];
char curChar;
attrib = nsIMsgFilterList::attribNone;
curChar = SkipWhitespace(aStream);
int i;
for (i = 0; i + 1 < (int)(sizeof(attribStr)); )
{
- if (curChar == (char) -1 || (!(curChar & 0x80) && isspace(curChar)) || curChar == '=')
+ if (curChar == EOF_CHAR || (!(curChar & 0x80) && isspace(curChar)) || curChar == '=')
break;
attribStr[i++] = curChar;
curChar = ReadChar(aStream);
}
attribStr[i] = '\0';
for (unsigned int tableIndex = 0; tableIndex < sNumFilterFileAttribTable; tableIndex++)
{
if (!PL_strcasecmp(attribStr, FilterFileAttribTable[tableIndex].attribName))
@@ -476,26 +478,26 @@ nsresult nsMsgFilterList::LoadValue(nsCS
else
{
valueStr += curChar;
curChar = nextChar;
}
}
else
{
- if (curChar == (char) -1 || curChar == '"' || curChar == '\n' || curChar == '\r')
+ if (curChar == EOF_CHAR || curChar == '"' || curChar == '\n' || curChar == '\r')
{
value += valueStr;
break;
}
}
valueStr += curChar;
curChar = ReadChar(aStream);
}
- while (curChar != -1);
+ while (curChar != EOF_CHAR);
return NS_OK;
}
nsresult nsMsgFilterList::LoadTextFilters(nsIInputStream *aStream)
{
nsresult err = NS_OK;
uint64_t bytesAvailable;
@@ -508,17 +510,17 @@ nsresult nsMsgFilterList::LoadTextFilter
// We'd really like to move lot's of these into the objects that they refer to.
do
{
nsAutoCString value;
nsresult intToStringResult;
char curChar;
curChar = LoadAttrib(attrib, bufStream);
- if (curChar == (char) -1) //reached eof
+ if (curChar == EOF_CHAR) //reached eof
break;
err = LoadValue(value, bufStream);
if (NS_FAILED(err))
break;
switch(attrib)
{
case nsIMsgFilterList::attribNone:

View file

@ -3,7 +3,6 @@
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - mozconfig additions used in xulrunner, just in case
# - patch to fix usage of char on ARM
pkgname=seamonkey
pkgver=2.33
@ -22,13 +21,11 @@ url="http://www.seamonkey-project.org/"
source=(ftp://ftp.mozilla.org/pub/mozilla.org/$pkgname/releases/$pkgver/source/$pkgname-$pkgver.source.tar.bz2
mozconfig
seamonkey-2.0-lang.patch
rhbz-966424.patch
273bcc4d6e9b.patch)
rhbz-966424.patch)
md5sums=('94a2ff3ac33602218fea4dfb5ef4af16'
'806cb42b072a8e749685ae6eafefb4ec'
'25b6fe16ac24cd5c852213e5c1adb272'
'8c1578232b7a60fa1caa9a0b322d1e2b'
'def94406c9989638254da0b80836da55')
'8c1578232b7a60fa1caa9a0b322d1e2b')
prepare() {
cd comm-release