$OpenBSD: patch-glib_gprintf_c,v 1.6 2010/09/30 07:17:19 ajacoutot Exp $ --- glib/gprintf.c.orig Mon Sep 13 17:57:51 2010 +++ glib/gprintf.c Mon Sep 27 14:42:36 2010 @@ -87,6 +87,8 @@ g_fprintf (FILE *file, return retval; } +__warn_references(g_sprintf, + "warning: g_sprintf() is often misused, please use g_snprintf()"); /** * g_sprintf: * @string: A pointer to a memory buffer to contain the resulting string. It @@ -215,6 +217,8 @@ g_vfprintf (FILE *file, return _g_vfprintf (file, format, args); } +__warn_references(g_vsprintf, + "warning: g_vsprintf() is often misused, please use g_vsnprintf()"); /** * g_vsprintf: * @string: the buffer to hold the output.