[gtk/matthiasc/css-values: 6/23] cssarrayvalue: Reserve 2 pointers when parsing array values
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/matthiasc/css-values: 6/23] cssarrayvalue: Reserve 2 pointers when parsing array values
- Date: Fri, 10 Jan 2020 19:17:37 +0000 (UTC)
commit f0affa8886d8b64f676f9411a7fecdd4b7e29752
Author: Timm Bäder <mail baedert org>
Date: Wed Jan 8 08:58:07 2020 +0100
cssarrayvalue: Reserve 2 pointers when parsing array values
given that we parse an array, chances are we're gonna see 2 values.
gtk/gtkcssarrayvalue.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gtk/gtkcssarrayvalue.c b/gtk/gtkcssarrayvalue.c
index 60019fea5c..02ece79fbd 100644
--- a/gtk/gtkcssarrayvalue.c
+++ b/gtk/gtkcssarrayvalue.c
@@ -413,7 +413,7 @@ _gtk_css_array_value_parse (GtkCssParser *parser,
GtkCssValue *value, *result;
GPtrArray *values;
- values = g_ptr_array_new ();
+ values = g_ptr_array_sized_new (2);
do {
value = parse_func (parser);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]