From 71aaa2eaa25f1a6bc958c5dcffa79b478ddfa664 Mon Sep 17 00:00:00 2001 From: Calvince Otieno Date: Tue, 18 Oct 2022 20:21:13 +0300 Subject: [PATCH] tdf#42982 Make UNO error reporting more descriptive Change-Id: I1f1c8285a1d41a9c9694a54c0bdfb20c6f0b27ed Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141512 Tested-by: Jenkins Tested-by: Ilmari Lauhakangas Reviewed-by: Ilmari Lauhakangas --- canvas/source/directx/dx_bitmap.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/canvas/source/directx/dx_bitmap.cxx b/canvas/source/directx/dx_bitmap.cxx index d1f683da6bd9..880e51e78d56 100644 --- a/canvas/source/directx/dx_bitmap.cxx +++ b/canvas/source/directx/dx_bitmap.cxx @@ -154,7 +154,7 @@ namespace dxcanvas // getMemoryLayout &aBmpData ) ) { - throw uno::RuntimeException(); + throw uno::RuntimeException("Internal error while writing BitmapData into Bitmap"); } // commit data to bitmap @@ -177,7 +177,7 @@ namespace dxcanvas if( Gdiplus::Ok != mpBitmap->SetPixel( pos.X, pos.Y, Gdiplus::Color( tools::sequenceToArgb( color )))) { - throw uno::RuntimeException(); + throw uno::RuntimeException("SetPixel called with invalid x,y points or color"); } }