diff options
Diffstat (limited to 'fxbarcode')
-rw-r--r-- | fxbarcode/oned/BC_OnedCodaBarWriter.cpp | 1 | ||||
-rw-r--r-- | fxbarcode/oned/BC_OnedCode39Writer.cpp | 1 | ||||
-rw-r--r-- | fxbarcode/oned/BC_OnedEAN13Writer.cpp | 1 | ||||
-rw-r--r-- | fxbarcode/oned/BC_OnedEAN8Writer.cpp | 1 | ||||
-rw-r--r-- | fxbarcode/oned/BC_OnedUPCAWriter.cpp | 1 |
5 files changed, 5 insertions, 0 deletions
diff --git a/fxbarcode/oned/BC_OnedCodaBarWriter.cpp b/fxbarcode/oned/BC_OnedCodaBarWriter.cpp index 42990f7f3a..c51b1c2eb9 100644 --- a/fxbarcode/oned/BC_OnedCodaBarWriter.cpp +++ b/fxbarcode/oned/BC_OnedCodaBarWriter.cpp @@ -109,6 +109,7 @@ bool CBC_OnedCodaBarWriter::CheckContentValidity( WideString CBC_OnedCodaBarWriter::FilterContents( const WideStringView& contents) { WideString filtercontents; + filtercontents.Reserve(contents.GetLength()); wchar_t ch; for (size_t index = 0; index < contents.GetLength(); index++) { ch = contents[index]; diff --git a/fxbarcode/oned/BC_OnedCode39Writer.cpp b/fxbarcode/oned/BC_OnedCode39Writer.cpp index f04dc195ea..9152155e29 100644 --- a/fxbarcode/oned/BC_OnedCode39Writer.cpp +++ b/fxbarcode/oned/BC_OnedCode39Writer.cpp @@ -73,6 +73,7 @@ bool CBC_OnedCode39Writer::CheckContentValidity( WideString CBC_OnedCode39Writer::FilterContents( const WideStringView& contents) { WideString filtercontents; + filtercontents.Reserve(contents.GetLength()); for (size_t i = 0; i < contents.GetLength(); i++) { wchar_t ch = contents[i]; if (ch == L'*' && (i == 0 || i == contents.GetLength() - 1)) { diff --git a/fxbarcode/oned/BC_OnedEAN13Writer.cpp b/fxbarcode/oned/BC_OnedEAN13Writer.cpp index 6818d432d6..1facf9ee26 100644 --- a/fxbarcode/oned/BC_OnedEAN13Writer.cpp +++ b/fxbarcode/oned/BC_OnedEAN13Writer.cpp @@ -62,6 +62,7 @@ bool CBC_OnedEAN13Writer::CheckContentValidity(const WideStringView& contents) { WideString CBC_OnedEAN13Writer::FilterContents(const WideStringView& contents) { WideString filtercontents; + filtercontents.Reserve(contents.GetLength()); wchar_t ch; for (size_t i = 0; i < contents.GetLength(); i++) { ch = contents[i]; diff --git a/fxbarcode/oned/BC_OnedEAN8Writer.cpp b/fxbarcode/oned/BC_OnedEAN8Writer.cpp index 6862ba87a1..b953c121b0 100644 --- a/fxbarcode/oned/BC_OnedEAN8Writer.cpp +++ b/fxbarcode/oned/BC_OnedEAN8Writer.cpp @@ -69,6 +69,7 @@ bool CBC_OnedEAN8Writer::CheckContentValidity(const WideStringView& contents) { WideString CBC_OnedEAN8Writer::FilterContents(const WideStringView& contents) { WideString filtercontents; + filtercontents.Reserve(contents.GetLength()); wchar_t ch; for (size_t i = 0; i < contents.GetLength(); i++) { ch = contents[i]; diff --git a/fxbarcode/oned/BC_OnedUPCAWriter.cpp b/fxbarcode/oned/BC_OnedUPCAWriter.cpp index daabe9eb3b..eb895294aa 100644 --- a/fxbarcode/oned/BC_OnedUPCAWriter.cpp +++ b/fxbarcode/oned/BC_OnedUPCAWriter.cpp @@ -52,6 +52,7 @@ bool CBC_OnedUPCAWriter::CheckContentValidity(const WideStringView& contents) { WideString CBC_OnedUPCAWriter::FilterContents(const WideStringView& contents) { WideString filtercontents; + filtercontents.Reserve(contents.GetLength()); wchar_t ch; for (size_t i = 0; i < contents.GetLength(); i++) { ch = contents[i]; |