diff options
author | Caolán McNamara <caolanm@redhat.com> | 2013-03-03 15:43:33 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-03-04 11:23:58 +0000 |
commit | 3abfdd08caf588577c349f1e2cbe8778ec228c85 (patch) | |
tree | bbcab80605e9cb80423f14eeb14faacc5b2d02a7 /basegfx/inc/basegfx | |
parent | 5c2d43d25b98c05af0f9a7f126101c3b8fd7271f (diff) |
it's surely a bad idea to not crash in dbgutil mode but crash in product mode
Change-Id: Ie72e23a5b3c49b08bcf25a9de2d7c4d4c4e7925d
Diffstat (limited to 'basegfx/inc/basegfx')
-rw-r--r-- | basegfx/inc/basegfx/pixel/bpixel.hxx | 3 | ||||
-rw-r--r-- | basegfx/inc/basegfx/raster/bpixelraster.hxx | 16 |
2 files changed, 2 insertions, 17 deletions
diff --git a/basegfx/inc/basegfx/pixel/bpixel.hxx b/basegfx/inc/basegfx/pixel/bpixel.hxx index a2c59101fa78..09f0feaa808a 100644 --- a/basegfx/inc/basegfx/pixel/bpixel.hxx +++ b/basegfx/inc/basegfx/pixel/bpixel.hxx @@ -125,9 +125,6 @@ namespace basegfx { return (rPixel.maPixelUnion.maCombinedRGBO.mnValue != maPixelUnion.maCombinedRGBO.mnValue); } - - // empty element - static const BPixel& getEmptyBPixel(); }; ////////////////////////////////////////////////////////////////////////// diff --git a/basegfx/inc/basegfx/raster/bpixelraster.hxx b/basegfx/inc/basegfx/raster/bpixelraster.hxx index 60a5d5ab5e3a..ed7ac931d805 100644 --- a/basegfx/inc/basegfx/raster/bpixelraster.hxx +++ b/basegfx/inc/basegfx/raster/bpixelraster.hxx @@ -81,26 +81,14 @@ namespace basegfx // data access read only const BPixel& getBPixel(sal_uInt32 nIndex) const { -#ifdef DBG_UTIL - if(nIndex >= mnCount) - { - OSL_FAIL("getBPixel: Access out of range (!)"); - return BPixel::getEmptyBPixel(); - } -#endif + assert(nIndex < mnCount); //Access out of range return mpContent[nIndex]; } // data access read/write BPixel& getBPixel(sal_uInt32 nIndex) { -#ifdef DBG_UTIL - if(nIndex >= mnCount) - { - OSL_FAIL("getBPixel: Access out of range (!)"); - return mpContent[0L]; - } -#endif + assert(nIndex < mnCount); //Access out of range return mpContent[nIndex]; } }; |