diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-01-19 10:53:27 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-01-19 10:53:27 +0100 |
commit | 8404dc3c76babbc9d0a165f4046a6e5e1be35fe5 (patch) | |
tree | 78c6c2a1efd230e1510adfaa50f4b43f12e80332 /sc/source | |
parent | 811d1f0a0428a293d829d2c3d90bf3e8bbe1be90 (diff) |
-Werror=address (GCC 6)
"the compiler can assume that the address of ‘rItem’ will never be NULL"
Change-Id: I90a8a3074c2dab427b4bc6345ec4a824eb2ac249
Diffstat (limited to 'sc/source')
-rw-r--r-- | sc/source/ui/app/scmod.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx index 6fbbf926882b..162e355fd4e4 100644 --- a/sc/source/ui/app/scmod.cxx +++ b/sc/source/ui/app/scmod.cxx @@ -467,8 +467,9 @@ void ScModule::Execute( SfxRequest& rReq ) case SID_PSZ_FUNCTION: if (pReqArgs) { - const SfxUInt16Item& rItem = static_cast<const SfxUInt16Item&>(pReqArgs->Get(SID_PSZ_FUNCTION)); - OSL_ENSURE(dynamic_cast<const SfxUInt16Item*>( &rItem) != nullptr,"wrong Parameter"); + auto const & p = pReqArgs->Get(SID_PSZ_FUNCTION); + OSL_ENSURE(dynamic_cast<const SfxUInt16Item*>(&p) != nullptr,"wrong Parameter"); + const SfxUInt16Item& rItem = static_cast<const SfxUInt16Item&>(p); ScAppOptions aNewOpts( GetAppOptions() ); aNewOpts.SetStatusFunc( rItem.GetValue() ); |