Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
05362fd2
Kaydet (Commit)
05362fd2
authored
Kas 18, 2014
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
coverity#1242708 Untrusted loop bound
Change-Id: Ic5af417ad38cafa46051789574239996a8845ffb
üst
772a3693
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
xilink.cxx
sc/source/filter/excel/xilink.cxx
+11
-0
No files found.
sc/source/filter/excel/xilink.cxx
Dosyayı görüntüle @
05362fd2
...
@@ -272,6 +272,17 @@ XclImpExtName::MOper::MOper(svl::SharedStringPool& rPool, XclImpStream& rStrm) :
...
@@ -272,6 +272,17 @@ XclImpExtName::MOper::MOper(svl::SharedStringPool& rPool, XclImpStream& rStrm) :
{
{
SCSIZE
nLastCol
=
rStrm
.
ReaduInt8
();
SCSIZE
nLastCol
=
rStrm
.
ReaduInt8
();
SCSIZE
nLastRow
=
rStrm
.
ReaduInt16
();
SCSIZE
nLastRow
=
rStrm
.
ReaduInt16
();
//assuming worse case scenario of nOp + one byte unistring len
const
size_t
nMinRecordSize
=
2
;
const
size_t
nMaxRows
=
rStrm
.
GetRecLeft
()
/
(
nMinRecordSize
*
(
nLastCol
+
1
));
if
(
nLastRow
>=
nMaxRows
)
{
SAL_WARN
(
"sc"
,
"Parsing error: "
<<
nMaxRows
<<
" max possible rows, but "
<<
nLastRow
<<
" index claimed, truncating"
);
nLastRow
=
nMaxRows
-
1
;
}
mxCached
->
Resize
(
nLastCol
+
1
,
nLastRow
+
1
);
mxCached
->
Resize
(
nLastCol
+
1
,
nLastRow
+
1
);
for
(
SCSIZE
nRow
=
0
;
nRow
<=
nLastRow
;
++
nRow
)
for
(
SCSIZE
nRow
=
0
;
nRow
<=
nLastRow
;
++
nRow
)
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment