Protect pasteboard GtkTargetPair flag values from being out of range

This commit is contained in:
John Ralls 2012-08-22 14:38:53 -07:00
parent 2cb739a2d5
commit d6a559216f

View File

@ -101,6 +101,7 @@ _gtk_quartz_target_list_to_pasteboard_types (GtkTargetList *target_list)
{
GtkTargetPair *pair = list->data;
gchar *target = gdk_atom_name (pair->target);
g_return_val_if_fail (pair->flags < 16, NULL);
[set addObject:target_to_pasteboard_type (target)];
g_free (target);
}