]> git.lyx.org Git - lyx.git/blobdiff - src/insets/insetenv.C
prevent crash when inserting minipage in table cell,
[lyx.git] / src / insets / insetenv.C
index 7a5215af55c0dc77e0930a7b6351cf454215c7d7..7e6c7ad70f05eac072ba36ee8dba313bc5b6c804 100644 (file)
@@ -23,6 +23,7 @@
 
 using std::ostream;
 using std::endl;
+using std::auto_ptr;
 
 
 InsetEnvironment::InsetEnvironment
@@ -40,9 +41,9 @@ InsetEnvironment::InsetEnvironment(InsetEnvironment const & in)
 {}
 
 
-Inset * InsetEnvironment::clone(Buffer const &) const
+auto_ptr<InsetBase> InsetEnvironment::clone() const
 {
-       return new InsetEnvironment(*this);
+       return auto_ptr<InsetBase>(new InsetEnvironment(*this));
 }