On Tue, Apr 1, 2008 at 10:52 PM, Guilherme Polo <ggpolo_at_gmail.com> wrote:
> But, for PyGtk 2.8 and earlier I would suggest doing this in a
> different manner (and much simpler and less error-prone):
>
> try:
> import gtk
> except ImportError, e:
> print e
>
> For PyGtk 2.10 and newer, ImportError is actually a warning so the
> code changes a bit:
>
> import warnings
> warnings.filterwarnings('error', module='gtk')
> try:
> import gtk
> except Warning, w:
> print w
> warnings.resetwarnings()
>
I think that just display the an eventually warning is not enough. We
have to leave segfault. By this way we have to check if the waring is
associated to display too.
Att, Joćo Medeiros.
_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://SecLists.Org
Received on Apr 01 2008