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

Unified Diff: apps/moterm/moterm_driver.cc

Issue 1397133002: Remove callers of mojo::Array<size_t> constructor in favor of ::New (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 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 | « no previous file | examples/moterm_example_app/moterm_example_app.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: apps/moterm/moterm_driver.cc
diff --git a/apps/moterm/moterm_driver.cc b/apps/moterm/moterm_driver.cc
index c55671950973879b19c360f8b02980dc002bd11c..a6af1da07545735338268809e10fed765e810e3f 100644
--- a/apps/moterm/moterm_driver.cc
+++ b/apps/moterm/moterm_driver.cc
@@ -134,7 +134,7 @@ void MotermDriver::CompletePendingReads() {
size_t data_size = std::min(static_cast<size_t>(pending_read.num_bytes),
send_data_queue_.size());
- mojo::Array<uint8_t> data(data_size);
+ auto data = mojo::Array<uint8_t>::New(data_size);
for (size_t i = 0; i < data_size; i++) {
data[i] = send_data_queue_[i];
// In canonical mode, each read only gets a single line.
« no previous file with comments | « no previous file | examples/moterm_example_app/moterm_example_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698