Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6100)

Unified Diff: chrome/browser/history/scored_history_match.cc

Issue 10540082: Coverity: Remove dead code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/history/scored_history_match.cc
diff --git a/chrome/browser/history/scored_history_match.cc b/chrome/browser/history/scored_history_match.cc
index 8f8c3737f1dcc70e974c7d71222fd1705eb30fec..2f83ab8c6450f09370af8ff6456173e875c31c20 100644
--- a/chrome/browser/history/scored_history_match.cc
+++ b/chrome/browser/history/scored_history_match.cc
@@ -444,14 +444,11 @@ void ScoredHistoryMatch::FillInDaysAgoToRecencyScoreArray() {
// Linearly extrapolate between 30 and 90 days so 90 days has a score
// of 20.
unnormalized_recency_score = 20 + (90 - days_ago) * (50 - 20) / (90 - 30);
- } else if (days_ago <= 365) {
+ } else {
// Linearly extrapolate between 90 and 365 days so 365 days has a score
// of 10.
unnormalized_recency_score =
10 + (365 - days_ago) * (20 - 10) / (365 - 90);
- } else {
- // greater than a year.
- unnormalized_recency_score = 10;
kmadhusu 2012/06/08 19:51:14 Since days_ago is always between 0 and 365, execut
James Hawkins 2012/06/12 20:38:57 Hmm I looked at this Coverity defect, and had rese
}
days_ago_to_recency_score[days_ago] = unnormalized_recency_score / 100.0;
if (days_ago > 0) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698