[Libreoffice-commits] core.git: include/oox

David Ostrovsky david at ostrovsky.org
Wed Sep 9 23:12:07 PDT 2015


 include/oox/helper/binaryinputstream.hxx  |    4 ++++
 include/oox/helper/binaryoutputstream.hxx |    4 ++++
 2 files changed, 8 insertions(+)

New commits:
commit 5066199663e40aad46e769ca3372f5f0b9915789
Author: David Ostrovsky <david at ostrovsky.org>
Date:   Thu Sep 3 23:51:56 2015 +0200

    oox: workaround C2249 error on MSVC 14.0
    
    The member is inherited from a nonpublic virtual base class or
    structure.
    
    Declaring copy ctor and assignment operator as deleted in derived
    class solved the problem.
    
    Change-Id: Ic509f7e7311fd896656ecff80df3ece4503c3a65
    Reviewed-on: https://gerrit.libreoffice.org/18328
    Reviewed-by: David Ostrovsky <david at ostrovsky.org>
    Tested-by: David Ostrovsky <david at ostrovsky.org>

diff --git a/include/oox/helper/binaryinputstream.hxx b/include/oox/helper/binaryinputstream.hxx
index cb7fb90..423af9c 100644
--- a/include/oox/helper/binaryinputstream.hxx
+++ b/include/oox/helper/binaryinputstream.hxx
@@ -220,6 +220,10 @@ protected:
     /** This dummy default c'tor will never call the c'tor of the virtual base
         class BinaryStreamBase as this class cannot be instantiated directly. */
     BinaryInputStream() : BinaryStreamBase( false ) {}
+
+private:
+    BinaryInputStream( BinaryInputStream const& ) = delete;
+    BinaryInputStream& operator=( BinaryInputStream const& ) = delete;
 };
 
 typedef std::shared_ptr< BinaryInputStream > BinaryInputStreamRef;
diff --git a/include/oox/helper/binaryoutputstream.hxx b/include/oox/helper/binaryoutputstream.hxx
index 52160da..49eb7e7 100644
--- a/include/oox/helper/binaryoutputstream.hxx
+++ b/include/oox/helper/binaryoutputstream.hxx
@@ -86,6 +86,10 @@ protected:
     /** This dummy default c'tor will never call the c'tor of the virtual base
         class BinaryStreamBase as this class cannot be instantiated directly. */
     BinaryOutputStream() : BinaryStreamBase( false ) {}
+
+private:
+    BinaryOutputStream( BinaryOutputStream const& ) = delete;
+    BinaryOutputStream& operator=( BinaryOutputStream const& ) = delete;
 };
 
 template< typename Type >


More information about the Libreoffice-commits mailing list