gettext_initialization ();
+#ifdef SIGPIPE
+ signal (SIGPIPE, SIG_IGN);
+#endif
+
if (g_fatal_warnings)
{
GLogLevelFlags fatal_mask;
gboolean
gtk_init_with_args (int *argc,
char ***argv,
- char *parameter_string,
+ const char *parameter_string,
GOptionEntry *entries,
- char *translation_domain,
+ const char *translation_domain,
GError **error)
{
GOptionContext *context;
* the GUI for some reason. If you want your program to fall back to a
* textual interface you want to call gtk_init_check() instead.
* </para></note>
+ *
+ * <note><para>
+ * Since 2.18, GTK+ calls <literal>signal (SIGPIPE, SIG_IGN)</literal>
+ * during initialization, to ignore SIGPIPE signals, since these are
+ * almost never wanted in graphical applications. If you do need to
+ * handle SIGPIPE for some reason, reset the handler after gtk_init(),
+ * but notice that other libraries (e.g. libdbus or gvfs) might do
+ * similar things.
+ * </para></note>
**/
void
gtk_init (int *argc, char ***argv)