Index: trunk/src/main.c =================================================================== --- trunk/src/main.c (revision 321) +++ trunk/src/main.c (revision 322) @@ -1585,7 +1585,6 @@ * - register 'call on exit()' function */ -#include "action_list.h" setbuf (stdout, 0); InitPaths (argv[0]); @@ -1648,6 +1647,11 @@ if (!gui) exit (1); +/* Initialize actions only when the gui is already known so only the right + one is registered (there can be only one GUI). */ +#include "action_list.h" + + /* Set up layers. */ for (i = 0; i < MAX_LAYER; i++) {