| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/base/net_log_logger.h" | 5 #include "net/base/net_log_logger.h" |
| 6 | 6 |
| 7 #include <stdio.h> | 7 #include <stdio.h> |
| 8 | 8 |
| 9 #include "base/json/json_writer.h" | 9 #include "base/json/json_writer.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 std::string json; | 55 std::string json; |
| 56 base::JSONWriter::Write(value.get(), &json); | 56 base::JSONWriter::Write(value.get(), &json); |
| 57 fprintf(file_.get(), "%s%s", | 57 fprintf(file_.get(), "%s%s", |
| 58 (added_events_ ? ",\n" : ""), | 58 (added_events_ ? ",\n" : ""), |
| 59 json.c_str()); | 59 json.c_str()); |
| 60 added_events_ = true; | 60 added_events_ = true; |
| 61 } | 61 } |
| 62 | 62 |
| 63 // static | 63 // static |
| 64 base::DictionaryValue* NetLogLogger::GetConstants() { | 64 base::DictionaryValue* NetLogLogger::GetConstants() { |
| 65 return GetNetConstants().get(); | 65 return GetNetConstants().release(); |
| 66 } | 66 } |
| 67 | 67 |
| 68 } // namespace net | 68 } // namespace net |
| OLD | NEW |