[Libreoffice-commits] core.git: hwpfilter/source

Caolán McNamara caolanm at redhat.com
Sat Mar 4 20:43:11 UTC 2017


 hwpfilter/source/hbox.cxx    |    2 --
 hwpfilter/source/hbox.h      |    3 +--
 hwpfilter/source/hwpread.cxx |    3 +--
 3 files changed, 2 insertions(+), 6 deletions(-)

New commits:
commit db86b38c54baae620cd3074e70d99b08a7592a57
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sat Mar 4 20:42:13 2017 +0000

    bin is unused
    
    Change-Id: I5168b18898cff023ab014a86e7afc82d7b69f363

diff --git a/hwpfilter/source/hbox.cxx b/hwpfilter/source/hbox.cxx
index 950fc91..4977e6d 100644
--- a/hwpfilter/source/hbox.cxx
+++ b/hwpfilter/source/hbox.cxx
@@ -95,7 +95,6 @@ FieldCode::FieldCode()
     , str1(nullptr)
     , str2(nullptr)
     , str3(nullptr)
-    , bin(nullptr)
     , m_pDate(nullptr)
 {
     reserved1 = new char[4];
@@ -107,7 +106,6 @@ FieldCode::~FieldCode()
     delete[] str1;
     delete[] str2;
     delete[] str3;
-    delete[] bin;
     delete[] reserved1;
     delete[] reserved2;
     delete m_pDate;
diff --git a/hwpfilter/source/hbox.h b/hwpfilter/source/hbox.h
index 78325a5..979d8a0 100644
--- a/hwpfilter/source/hbox.h
+++ b/hwpfilter/source/hbox.h
@@ -90,9 +90,8 @@ struct FieldCode : public HBox
     hchar *str1;
     hchar *str2;
     hchar *str3;
-    char *bin;
 
-     DateCode *m_pDate;
+    DateCode *m_pDate;
 
     FieldCode();
     virtual ~FieldCode() override;
diff --git a/hwpfilter/source/hwpread.cxx b/hwpfilter/source/hwpread.cxx
index aefb97a..2cc6d31 100644
--- a/hwpfilter/source/hwpread.cxx
+++ b/hwpfilter/source/hwpread.cxx
@@ -86,7 +86,6 @@ bool FieldCode::Read(HWPFile & hwpf)
     str1 = new hchar[len1_ ? len1_ : 1];
     str2 = new hchar[len2_ ? len2_ : 1];
     str3 = new hchar[len3_ ? len3_ : 1];
-    bin = new char[binlen];
 
     hwpf.Read2b(str1, len1_);
     hwpf.SkipBlock(len1 - (len1_ * sizeof(hchar)));
@@ -98,7 +97,7 @@ bool FieldCode::Read(HWPFile & hwpf)
     hwpf.SkipBlock(len3 - (len3_ * sizeof(hchar)));
     str3[len3_ ? (len3_ - 1) : 0] = 0;
 
-    hwpf.ReadBlock(bin, binlen);
+    hwpf.SkipBlock(binlen);
 
      if( type[0] == 3 && type[1] == 2 ){ /* It must create a format as created date. */
           DateCode *pDate = new DateCode;


More information about the Libreoffice-commits mailing list