mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-27 06:00:22 +00:00
printing: Properly initialize auth_info in gtkprintbackend.c
auth_info should be a NULL-terminated array as it is used in e.g. g_strdupv invocations iterating over its elements until a NULL element is encountered. https://bugzilla.gnome.org/show_bug.cgi?id=737777
This commit is contained in:
parent
0bf474e324
commit
15dbadf389
@ -756,7 +756,7 @@ request_password (GtkPrintBackend *backend,
|
||||
|
||||
priv->auth_info_required = g_strdupv (ai_required);
|
||||
length = g_strv_length (ai_required);
|
||||
priv->auth_info = g_new0 (gchar *, length);
|
||||
priv->auth_info = g_new0 (gchar *, length + 1);
|
||||
priv->store_auth_info = FALSE;
|
||||
|
||||
dialog = gtk_dialog_new_with_buttons ( _("Authentication"), NULL, GTK_DIALOG_MODAL,
|
||||
|
Loading…
Reference in New Issue
Block a user