C++11 and whitespace cleanups.
[dcpomatic.git] / src / lib / ext.cc
index ec34f147216d97af091fdaaeec060c9620403fef..af5229f72f41c02941f6905911eb34495be91d61 100644 (file)
@@ -248,8 +248,8 @@ copy (boost::filesystem::path from, boost::filesystem::path to, uint64_t& total_
                }
                set_timestamps_to_now (cr);
 
-               for (directory_iterator i = directory_iterator(from); i != directory_iterator(); ++i) {
-                       copy (i->path(), cr, total_remaining, total, copied_files, nanomsg);
+               for (auto i: directory_iterator(from)) {
+                       copy (i.path(), cr, total_remaining, total, copied_files, nanomsg);
                }
        } else {
                string const write_digest = write (from, cr, total_remaining, total, nanomsg);