diff options
author | Chun-wei Fan <fanc999@yahoo.com.tw> | 2018-10-09 16:22:28 +0800 |
---|---|---|
committer | Chun-wei Fan <fanc999@yahoo.com.tw> | 2018-10-09 16:26:21 +0800 |
commit | 1ca906008ecfd94077a0fe1c607f13a8de83d4b8 (patch) | |
tree | 5cd184576a17adf82e80d520c425166f07f7c361 | |
parent | cbb0d7ba69496ebe8b4b663d9a5572cf11622588 (diff) | |
download | gtk+-1ca906008ecfd94077a0fe1c607f13a8de83d4b8.tar.gz |
testsuite/gtk/[flatten|sort]listmodel.c: Avoid VLA usage
Visual Studio is unlikely to support VLAs at any point, so avoid using
them and use g_newa() instead.
-rw-r--r-- | testsuite/gtk/flattenlistmodel.c | 2 | ||||
-rw-r--r-- | testsuite/gtk/sortlistmodel.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/testsuite/gtk/flattenlistmodel.c b/testsuite/gtk/flattenlistmodel.c index f522f1e121..c06e30b350 100644 --- a/testsuite/gtk/flattenlistmodel.c +++ b/testsuite/gtk/flattenlistmodel.c @@ -61,7 +61,7 @@ splice (GListStore *store, guint *numbers, guint added) { - GObject *objects[added]; + GObject **objects = g_newa (GObject *, added); guint i; for (i = 0; i < added; i++) diff --git a/testsuite/gtk/sortlistmodel.c b/testsuite/gtk/sortlistmodel.c index 31a6711f04..1b54d0b976 100644 --- a/testsuite/gtk/sortlistmodel.c +++ b/testsuite/gtk/sortlistmodel.c @@ -56,7 +56,7 @@ splice (GListStore *store, guint *numbers, guint added) { - GObject *objects[added]; + GObject **objects = g_newa (GObject *, added); guint i; for (i = 0; i < added; i++) |