]> gitweb @ CieloNegro.org - pkgsrc-firefox3.git/blob - patches/patch-ea
Initial revision of the upstream www/firefox3
[pkgsrc-firefox3.git] / patches / patch-ea
1 $NetBSD: patch-ea,v 1.2 2009/01/05 09:58:36 martin Exp $
2
3 --- toolkit/components/history/src/nsGlobalHistory.cpp.orig     2006-02-02 20:55:17.000000000 +0100
4 +++ toolkit/components/history/src/nsGlobalHistory.cpp
5 @@ -322,7 +322,9 @@ matchAgeInDaysCallback(nsIMdbRow *row, v
6    if (err != 0) return PR_FALSE;
7    
8    PRTime rowDate;
9 -  PR_sscanf((const char*)yarn.mYarn_Buf, "%lld", &rowDate);
10 +  long long ld;
11 +  PR_sscanf((const char*)yarn.mYarn_Buf, "%lld", &ld);
12 +  rowDate = ld;
13  
14    PRInt32 days = GetAgeInDays(matchSearchTerm->now, rowDate);
15    
16 @@ -1067,7 +1069,9 @@ nsGlobalHistory::GetRowValue(nsIMdbRow *
17    if (!yarn.mYarn_Fill || !yarn.mYarn_Buf)
18      return NS_OK;
19  
20 -  PR_sscanf((const char*)yarn.mYarn_Buf, "%lld", aResult);
21 +  long long ld;
22 +  PR_sscanf((const char*)yarn.mYarn_Buf, "%lld", &ld);
23 +  *aResult = ld;
24    
25    return NS_OK;
26  }
27 @@ -1153,6 +1157,9 @@ nsGlobalHistory::SetPageTitle(nsIURI *aU
28    rv = aURI->GetSpec(URISpec);
29    NS_ENSURE_SUCCESS(rv, rv);
30  
31 +  if (URISpec.Length() > HISTORY_URI_LENGTH_MAX)
32 +    URISpec.Left(URISpec, HISTORY_URI_LENGTH_MAX);
33 +
34    nsCOMPtr<nsIMdbRow> row;
35    rv = FindRow(kToken_URLColumn, URISpec.get(), getter_AddRefs(row));
36  
37