summaryrefslogtreecommitdiff
path: root/xfa/fxfa/parser/cxfa_widgetdata.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/fxfa/parser/cxfa_widgetdata.cpp')
-rw-r--r--xfa/fxfa/parser/cxfa_widgetdata.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/xfa/fxfa/parser/cxfa_widgetdata.cpp b/xfa/fxfa/parser/cxfa_widgetdata.cpp
index cbe0d14c91..1920e9f3fd 100644
--- a/xfa/fxfa/parser/cxfa_widgetdata.cpp
+++ b/xfa/fxfa/parser/cxfa_widgetdata.cpp
@@ -1323,7 +1323,10 @@ bool CXFA_WidgetData::GetBarcodeAttribute_WideNarrowRatio(float* val) {
} else {
int32_t fA, fB;
fA = FXSYS_wtoi(wsWideNarrowRatio.Left(ptPos).c_str());
- fB = FXSYS_wtoi(wsWideNarrowRatio.Mid(ptPos + 1).c_str());
+ fB = FXSYS_wtoi(
+ wsWideNarrowRatio
+ .Mid(ptPos + 1, wsWideNarrowRatio.GetLength() - (ptPos + 1))
+ .c_str());
if (fB)
fRatio = (float)fA / fB;
}