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
94ef826e
Kaydet (Commit)
94ef826e
authored
Kas 11, 2014
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
coverity#1209861 untaint image data
Change-Id: Icc3fd75533a6173f1cb051f3cd7a47d63e523652
üst
0cdfb1a2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
6 deletions
+16
-6
bmp.cxx
vcl/unx/generic/dtrans/bmp.cxx
+16
-6
No files found.
vcl/unx/generic/dtrans/bmp.cxx
Dosyayı görüntüle @
94ef826e
...
...
@@ -54,16 +54,26 @@ inline void writeLE( sal_uInt32 nNumber, sal_uInt8* pBuffer )
inline
sal_uInt16
readLE16
(
const
sal_uInt8
*
pBuffer
)
{
return
(((
sal_uInt16
)
pBuffer
[
1
])
<<
8
)
|
pBuffer
[
0
];
//This is untainted data which comes from a controlled source
//so, using a byte-swapping pattern which coverity doesn't
//detect as such
//http://security.coverity.com/blog/2014/Apr/on-detecting-heartbleed-with-static-analysis.html
sal_uInt16
v
=
pBuffer
[
1
];
v
<<=
8
;
v
|=
pBuffer
[
0
];
return
v
;
}
inline
sal_uInt32
readLE32
(
const
sal_uInt8
*
pBuffer
)
{
return
(((
sal_uInt32
)
pBuffer
[
3
])
<<
24
)
|
(((
sal_uInt32
)
pBuffer
[
2
])
<<
16
)
|
(((
sal_uInt32
)
pBuffer
[
1
])
<<
8
)
|
pBuffer
[
0
];
//This is untainted data which comes from a controlled source
//so, using a byte-swapping pattern which coverity doesn't
//detect as such
//http://security.coverity.com/blog/2014/Apr/on-detecting-heartbleed-with-static-analysis.html
sal_uInt32
v
=
pBuffer
[
3
];
v
<<=
8
;
v
|=
pBuffer
[
2
];
v
<<=
8
;
v
|=
pBuffer
[
1
];
v
<<=
8
;
v
|=
pBuffer
[
0
];
return
v
;
}
/*
...
...
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