summaryrefslogtreecommitdiffstats
path: root/webkit/glue/plugins/pepper_file_chooser.cc
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/glue/plugins/pepper_file_chooser.cc')
-rw-r--r--webkit/glue/plugins/pepper_file_chooser.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/webkit/glue/plugins/pepper_file_chooser.cc b/webkit/glue/plugins/pepper_file_chooser.cc
index 098d60d..576e205 100644
--- a/webkit/glue/plugins/pepper_file_chooser.cc
+++ b/webkit/glue/plugins/pepper_file_chooser.cc
@@ -118,8 +118,10 @@ void FileChooser::StoreChosenFiles(const std::vector<std::string>& files) {
next_chosen_file_index_ = 0;
std::vector<std::string>::const_iterator end_it = files.end();
for (std::vector<std::string>::const_iterator it = files.begin();
- it != end_it; it++)
- chosen_files_.push_back(new FileRef(module(), FilePath().AppendASCII(*it)));
+ it != end_it; it++) {
+ chosen_files_.push_back(make_scoped_refptr(
+ new FileRef(module(), FilePath().AppendASCII(*it))));
+ }
if (!completion_callback_.func)
return;