summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-03-22 16:06:35 +0000
committerTor Lillqvist <tml@collabora.com>2014-03-25 11:40:36 +0200
commit814711a1b42f504c55ac796afbe10df82f12654f (patch)
tree57286ab7e702aa53ae9793e054c25c3ba95871d7 /vcl
parent947e9c777458254fd97e8edb4ac1c3aec8363900 (diff)
coverity#705969 Dereference before null check
Change-Id: Icb19931bb529e6c2b98621a603cdb86011d68a9e (cherry picked from commit 51452b7afe858139076010decbe04758321a8396) Reviewed-on: https://gerrit.libreoffice.org/8732 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/gdi/print3.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx
index ad2329c1108e..a5c97450bd62 100644
--- a/vcl/source/gdi/print3.cxx
+++ b/vcl/source/gdi/print3.cxx
@@ -716,7 +716,7 @@ bool Printer::StartJob( const OUString& i_rJobName, boost::shared_ptr<vcl::Print
if( bError )
{
- mnError = ImplSalPrinterErrorCodeToVCL( mpPrinter->GetErrorCode() );
+ mnError = mpPrinter ? ImplSalPrinterErrorCodeToVCL(mpPrinter->GetErrorCode()) : 0;
if ( !mnError )
mnError = PRINTER_GENERALERROR;
i_pController->setJobState( mnError == PRINTER_ABORT