AU: Send a previous version event after reboot following an update.

The previous version event is sent along with the first update check. This is
best effort -- if the update check doesn't reach the server, the event is lost.

BUG=9198
TEST=unit tests, tested on device

Change-Id: I5ceb7c8e99ae54eb331f6ac58b8977d2a111461c

Review URL: http://codereview.chromium.org/5993007
diff --git a/update_attempter.cc b/update_attempter.cc
index 8139687..3ea1c18 100644
--- a/update_attempter.cc
+++ b/update_attempter.cc
@@ -289,6 +289,7 @@
   if (code == kActionCodeSuccess) {
     utils::WriteFile(kUpdateCompletedMarker, "", 0);
     prefs_->SetInt64(kPrefsDeltaUpdateFailures, 0);
+    prefs_->SetString(kPrefsPreviousVersion, omaha_request_params_.app_version);
     DeltaPerformer::ResetUpdateProgress(prefs_, false);
     SetStatusAndNotify(UPDATE_STATUS_UPDATED_NEED_REBOOT);