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
080e9c29
Kaydet (Commit)
080e9c29
authored
Eki 17, 2013
tarafından
Lionel Elie Mamane
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
bogus WaE: 'bValue' may be used uninitialized in this function
Change-Id: Ifde0f9370d093f447edac4899c5bbc7940da5a8c
üst
1fc195f7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
11 deletions
+3
-11
CheckBox.cxx
forms/source/component/CheckBox.cxx
+3
-11
No files found.
forms/source/component/CheckBox.cxx
Dosyayı görüntüle @
080e9c29
...
@@ -211,17 +211,13 @@ bool OCheckBoxModel::DbUseBool()
...
@@ -211,17 +211,13 @@ bool OCheckBoxModel::DbUseBool()
}
}
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
#if defined __GNUC__ && ! defined __clang__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
Any
OCheckBoxModel
::
translateDbColumnToControlValue
()
Any
OCheckBoxModel
::
translateDbColumnToControlValue
()
{
{
Any
aValue
;
Any
aValue
;
//////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////
// Set value in ControlModel
// Set value in ControlModel
bool
bValue
;
bool
bValue
=
bool
();
// avoid warning
if
(
DbUseBool
())
if
(
DbUseBool
())
{
{
bValue
=
m_xColumn
->
getBoolean
();
bValue
=
m_xColumn
->
getBoolean
();
...
@@ -247,17 +243,13 @@ Any OCheckBoxModel::translateDbColumnToControlValue()
...
@@ -247,17 +243,13 @@ Any OCheckBoxModel::translateDbColumnToControlValue()
{
{
// Since above either bValue is initialised, either aValue.hasValue(),
// Since above either bValue is initialised, either aValue.hasValue(),
// bValue cannot be used uninitialised here.
// bValue cannot be used uninitialised here.
// But GCC does not see/understand that, which breaks -Werror builds.
// But GCC does not see/understand that, which breaks -Werror builds,
// And Clang compiler does not support #pragma GCC diagnostic
// so we explicitly default-initialise it.
// within a function, moved them to outside the function.
aValue
<<=
(
sal_Int16
)(
bValue
?
STATE_CHECK
:
STATE_NOCHECK
);
aValue
<<=
(
sal_Int16
)(
bValue
?
STATE_CHECK
:
STATE_NOCHECK
);
}
}
return
aValue
;
return
aValue
;
}
}
#if defined __GNUC__ && ! defined __clang__
#pragma GCC diagnostic pop
#endif
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
sal_Bool
OCheckBoxModel
::
commitControlValueToDbColumn
(
bool
/*_bPostReset*/
)
sal_Bool
OCheckBoxModel
::
commitControlValueToDbColumn
(
bool
/*_bPostReset*/
)
...
...
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