mirror of https://gitee.com/openkylin/glib2.0.git
Do not fail the /thread/thread4 test if prlimit() fails
This happens on the Debian buildds. [smcv: Use g_test_skip()] Forwarded: no, Debian buildd specific
This commit is contained in:
parent
ddecc33cb3
commit
63c8beae1f
|
@ -145,7 +145,14 @@ test_thread4 (void)
|
||||||
nl.rlim_cur = 1;
|
nl.rlim_cur = 1;
|
||||||
|
|
||||||
if (prlimit (getpid (), RLIMIT_NPROC, &nl, &ol) != 0)
|
if (prlimit (getpid (), RLIMIT_NPROC, &nl, &ol) != 0)
|
||||||
g_error ("prlimit failed: %s", g_strerror (errno));
|
{
|
||||||
|
gchar *message = g_strdup_printf ("setting PRLIMIT_NPROC to {cur=%d,max=%d} failed: %s",
|
||||||
|
(int) nl.rlim_cur, (int) nl.rlim_max,
|
||||||
|
g_strerror (errno));
|
||||||
|
g_test_skip (message);
|
||||||
|
g_free (message);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
error = NULL;
|
error = NULL;
|
||||||
thread = g_thread_try_new ("a", thread1_func, NULL, &error);
|
thread = g_thread_try_new ("a", thread1_func, NULL, &error);
|
||||||
|
|
Loading…
Reference in New Issue