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
958bcfc9
Kaydet (Commit)
958bcfc9
authored
Ock 26, 2015
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
coverity#1266489 Untrusted loop bound
Change-Id: I5903dafb4bb29657a5b6e239cb918e656c381315
üst
dada981a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
9 deletions
+19
-9
tblafmt.cxx
sw/source/core/doc/tblafmt.cxx
+19
-9
No files found.
sw/source/core/doc/tblafmt.cxx
Dosyayı görüntüle @
958bcfc9
...
@@ -1165,19 +1165,29 @@ bool SwTableAutoFmtTbl::Load( SvStream& rStream )
...
@@ -1165,19 +1165,29 @@ bool SwTableAutoFmtTbl::Load( SvStream& rStream )
rStream
.
ReadUInt16
(
nAnz
);
rStream
.
ReadUInt16
(
nAnz
);
bRet
=
0
==
rStream
.
GetError
();
bRet
=
0
==
rStream
.
GetError
();
if
(
bRet
)
for
(
sal_uInt16
i
=
0
;
i
<
nAnz
;
++
i
)
{
{
pNew
=
new
SwTableAutoFmt
(
OUString
()
);
const
size_t
nMinRecordSize
=
sizeof
(
sal_uInt16
);
bRet
=
pNew
->
Load
(
rStream
,
aVersions
)
;
const
size_t
nMaxRecords
=
rStream
.
remainingSize
()
/
nMinRecordSize
;
if
(
bRet
)
if
(
nAnz
>
nMaxRecords
)
{
{
m_pImpl
->
m_AutoFormats
.
push_back
(
pNew
);
SAL_WARN
(
"vcl.gdi"
,
"Parsing error: "
<<
nMaxRecords
<<
" max possible entries, but "
<<
nAnz
<<
" claimed, truncating"
);
nAnz
=
nMaxRecords
;
}
}
else
for
(
sal_uInt16
i
=
0
;
i
<
nAnz
;
++
i
)
{
{
delete
pNew
;
pNew
=
new
SwTableAutoFmt
(
OUString
()
);
break
;
bRet
=
pNew
->
Load
(
rStream
,
aVersions
);
if
(
bRet
)
{
m_pImpl
->
m_AutoFormats
.
push_back
(
pNew
);
}
else
{
delete
pNew
;
break
;
}
}
}
}
}
}
}
...
...
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