Trucos e consellos para o depurado.
Sébastien Granjoux
seb.sfo@free.fr
Philip Chimento
philip.chimento@gmail.com

# Consellos para o depurado

# Corrixir erros críticos de Glib/GTK+

Sometimes it can be difficult to track down where GLib critical errors are occurring, since they do not stop the program. You can set the program to stop as soon as it gets a GLib critical error, by setting the environment variable G_DEBUG to the value fatal_criticals.

Open the by selecting Run Program Parameters... from the main menu.

Click the plus sign next to Environment Variables to expand the list of environment variables.

Prema Novo para engadir unha nova entrada á lista.

Fill in Name with G_DEBUG and Value with fatal_criticals.

Prema Aplicar para confirmar os cambios.

Execute o programa co depurador seleccionando Executar Depurar programa desde o menú principal.

Use o programa até que suceda o erro crítico.

When the debugger stops your program, look at the to check where this error comes from.

The top function with frame number 0 is in GLib, so you have to look down in the stack. Typically the error originates from the topmost function that belongs to your program.