tdf#117333 dbahsql exception handling
Lionel Elie Mamane
lionel at mamane.lu
Wed May 16 09:45:52 UTC 2018
It looks to me like your patch will not keep subtypes (types derived
from) SQLException, but will instead "truncate" them to a
SQLException, and thus lose information.
Additionally, I would suggest, instead of silently suppressing all
subsequent errors, to chain all errors in one SQLException and then to
show them all in one dialog.
An SQLException has a "NextException" member, just stick the next
exception there. To avoid a Schlemiel the Painter / quadratic
algorithm, you can do something like (and factorise it in function,
I'd say), with the right Any-magic operators (<<=, >>=, etc) instead of
while(pLastException->NextException is not empty)
// This assumes pLastException will be a SQLException;
// if it is not, I'm not sure what to do.
pLastException->NextException = ex;
On Wed, May 16, 2018 at 09:11:40AM +0000, bugzilla-daemon at bugs.documentfoundation.org wrote:
> --- Comment #3 from Commit Notification <libreoffice-commits at lists.freedesktop.org> ---
> Tamas Bunth committed a patch related to this issue.
> It has been pushed to "master":
> tdf#117333, tdf#117325 dbahsql: exception handling
> It will be available in 6.1.0.
> The patch should be included in the daily builds available at
> http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
> information about daily builds can be found at:
> Affected users are encouraged to test the fix and report feedback.
More information about the LibreOffice