Re: [mlview-list] [patch] Added error management in configuration backends
- From: Dodji Seketeli <dodji seketeli org>
- To: Nicolas Centa <happypeng mlview org>
- Cc: mlview-list gnome org
- Subject: Re: [mlview-list] [patch] Added error management in configuration backends
- Date: Sun, 24 Jul 2005 13:02:09 +0200
Hey Nicolas,
I have merged the patch, and made some changes to it.
>From what I understood, the spirit of the patch is to throw exceptions
when the calls to the underlying gconf client fail.
I think that's okay and I kept it.
The changes I made though are:
* don't use 'throw', but rather the THROW macro.
The THROW macro dumps the file/linenumber/method name/ of where
the exception whas thrown from. This is an invaluable resource
for debugging.
* don't define a custom exception class, use mlview::Exception class
thrown by the TROW macro.
* don't use Glib::ustring but rather mlview::UString.
The UString class doesn't throw an exception when you do
UString str = NULL, whereas Glib::ustring does.
* don't specify the throw(Foo) statement in methods declarations.
It'll take us too much time to make sure the code we use doesn't
throw anything else but Foo. And if we don't ensure that, the
"unexpected exception handler" will terminate the program.
Better keep things simple.
* use the mlview::SafePtr class to avoir leaking ressources in
methods that throw exceptions.
I have pushed the patch in mlview--main--0.9--patch-14
Thank you for you dedication.
Cheers,
Dodji.
On Sat, Jul 23, 2005 at 09:12:46PM +0200, Nicolas Centa wrote:
> Hello,
>
> This patch basically adds exceptions in the GConf configuration
> backend, if something fails.
>
> It's in mlview--main-happypeng--0.9--patch-4 (archive at
> http://arch.duckcorp.org/happypeng/2005-mlview), applies to
> mlview--main--0.9--patch-12 ; you can do cherrypicking with this
> patch.
>
> Cheers again,
>
> Nicolas Centa
> _______________________________________________
> Mlview-list mailing list
> Mlview-list gnome org
> http://mail.gnome.org/mailman/listinfo/mlview-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]