Fix lack of shared_ptr in makedcp.
authorCarl Hetherington <cth@carlh.net>
Thu, 25 Oct 2012 01:13:17 +0000 (02:13 +0100)
committerCarl Hetherington <cth@carlh.net>
Thu, 25 Oct 2012 01:13:17 +0000 (02:13 +0100)
src/tools/makedcp.cc

index 2d4df030c34094d0f8cefa01814d3b70bd2d97ff..c0fb7ccee3dff138d88370541261fd706daf3c4e 100644 (file)
@@ -147,9 +147,9 @@ main (int argc, char* argv[])
                cout << dependency_version_summary() << "\n";
        }
 
-       Film* film = 0;
+       shared_ptr<Film> film;
        try {
-               film = new Film (film_dir, true);
+               film.reset (new Film (film_dir, true));
        } catch (std::exception& e) {
                cerr << argv[0] << ": error reading film `" << film_dir << "' (" << e.what() << ")\n";
                exit (EXIT_FAILURE);