mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-05 00:46:16 +01:00
Fix the large array test to work
Fix by Sven Herzberg, bug 568760
This commit is contained in:
parent
21080a33e1
commit
dcdc409cd8
@ -115,7 +115,11 @@ array_large_size (void)
|
||||
g_array_set_size (array, 1073750016);
|
||||
exit (0); /* success */
|
||||
}
|
||||
g_test_trap_assert_passed ();
|
||||
|
||||
if (!g_test_trap_has_passed ())
|
||||
{
|
||||
g_test_trap_assert_stderr ("*failed to allocate 2147483648 bytes*");
|
||||
}
|
||||
|
||||
g_array_free (array, TRUE);
|
||||
}
|
||||
@ -315,9 +319,7 @@ main (int argc, char *argv[])
|
||||
g_test_add_func ("/array/append", array_append);
|
||||
g_test_add_func ("/array/prepend", array_prepend);
|
||||
g_test_add_func ("/array/ref-count", array_ref_count);
|
||||
#if 0
|
||||
g_test_add_func ("/array/large-size", array_large_size);
|
||||
#endif
|
||||
|
||||
/* pointer arrays */
|
||||
g_test_add_func ("/pointerarray/add", pointer_array_add);
|
||||
|
Loading…
Reference in New Issue
Block a user