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

Unified Diff: chrome/browser/feedback/feedback_util.cc

Issue 11265014: Add user agent string to feedback reports. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 | « chrome/browser/feedback/feedback_util.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/feedback/feedback_util.cc
diff --git a/chrome/browser/feedback/feedback_util.cc b/chrome/browser/feedback/feedback_util.cc
index b19f53d3882957724476b84ad3f8b299ff62fd59..5e3c4cef29385fa59db07fcd120e4d5b3c0bbb0e 100644
--- a/chrome/browser/feedback/feedback_util.cc
+++ b/chrome/browser/feedback/feedback_util.cc
@@ -26,6 +26,7 @@
#include "chrome/common/chrome_version_info.h"
#include "content/public/browser/navigation_controller.h"
#include "content/public/browser/web_contents.h"
+#include "content/public/common/content_client.h"
#include "googleurl/src/gurl.h"
#include "grit/generated_resources.h"
#include "grit/locale_settings.h"
@@ -263,6 +264,10 @@ void FeedbackUtil::SendReport(
userfeedback::CommonData* common_data = feedback_data.mutable_common_data();
userfeedback::WebData* web_data = feedback_data.mutable_web_data();
+ // Set our user agent.
+ userfeedback::Navigator* navigator = web_data->mutable_navigator();
+ navigator->set_user_agent(content::GetUserAgent(GURL()));
+
// Set GAIA id to 0. We're not using gaia id's for recording
// use feedback - we're using the e-mail field, allows users to
// submit feedback from incognito mode and specify any mail id
« no previous file with comments | « chrome/browser/feedback/feedback_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698