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

Unified Diff: chrome/browser/importer/safari_importer.mm

Issue 6594096: Clean up CF To NS Casts and make them slightly safer (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix space Created 9 years, 10 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/cocoa/keystone_glue.mm ('k') | chrome/browser/ui/cocoa/file_metadata.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/importer/safari_importer.mm
diff --git a/chrome/browser/importer/safari_importer.mm b/chrome/browser/importer/safari_importer.mm
index de406553e4ea051c1c5e75885f3df82eee9ecbcd..e65a41da1fccdada7801f16e36f4b44a5b1ef448 100644
--- a/chrome/browser/importer/safari_importer.mm
+++ b/chrome/browser/importer/safari_importer.mm
@@ -10,6 +10,7 @@
#include <vector>
#include "base/file_util.h"
+#include "base/mac/mac_util.h"
#include "base/message_loop.h"
#include "base/scoped_nsobject.h"
#include "base/string16.h"
@@ -326,7 +327,7 @@ double SafariImporter::HistoryTimeToEpochTime(NSString* history_time) {
// Add Difference between Unix epoch and CFAbsoluteTime epoch in seconds.
// Unix epoch is 1970-01-01 00:00:00.0 UTC,
// CF epoch is 2001-01-01 00:00:00.0 UTC.
- return CFStringGetDoubleValue(reinterpret_cast<CFStringRef>(history_time)) +
+ return CFStringGetDoubleValue(base::mac::NSToCFCast(history_time)) +
kCFAbsoluteTimeIntervalSince1970;
}
« no previous file with comments | « chrome/browser/cocoa/keystone_glue.mm ('k') | chrome/browser/ui/cocoa/file_metadata.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698