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 Gbp-Pq: Topic debian Gbp-Pq: Name 06_thread_test_ignore_prctl_fail.patch
This commit is contained in:
parent
cca0f81cec
commit
d2ebb1b201
|
@ -142,7 +142,14 @@ test_thread4 (void)
|
|||
nl.rlim_cur = 1;
|
||||
|
||||
if ((ret = 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;
|
||||
thread = g_thread_try_new ("a", thread1_func, NULL, &error);
|
||||
|
|
Loading…
Reference in New Issue