• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // SPDX-License-Identifier: GPL-2.0-or-later
2 /*
3  * Copyright (c) 2014 Fujitsu Ltd.
4  * Author: Zeng Linggang <zenglg.jy@cn.fujitsu.com>
5  */
6 /*\
7  * [Description]
8  *
9  * Check that if the calling process does not have any unwaited-for children
10  * wait() will return ECHILD.
11  */
12 
13 #include <sys/wait.h>
14 #include <sys/types.h>
15 #include "tst_test.h"
16 
verify_wait(void)17 static void verify_wait(void)
18 {
19 	TST_EXP_FAIL(wait(NULL), ECHILD);
20 }
21 
22 static struct tst_test test = {
23 	.test_all = verify_wait,
24 };
25