summaryrefslogtreecommitdiff
path: root/support/xstdio.h
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2019-11-19 17:17:05 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-02-27 15:52:35 -0300
commitdfe9aa91564c1bf2a23b5589a5db42f9da5d29b5 (patch)
treee0b278573ca44dd46752006e6caa978a65d655e6 /support/xstdio.h
parent5c8aa3849a58f2ef1d12ffb638a98578fbf99172 (diff)
downloadglibc-dfe9aa91564c1bf2a23b5589a5db42f9da5d29b5.tar.gz
support: Add support_process_state_wait
It allows parent process to wait for child state using a polling strategy over procfs on Linux. The polling is used over ptrace to avoid the need to handle signals on the target pid and to handle some system specific limitation (such as YAMA). The polling has some limitations, such as resource consumption due the procfs read in a loop and the lack of synchronization after the state is obtained. The interface idea is to simplify some sleep synchronization waitid tests and is to reduce timeouts by replacing arbitrary waits.
Diffstat (limited to 'support/xstdio.h')
-rw-r--r--support/xstdio.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/support/xstdio.h b/support/xstdio.h
index b62267a2a2..143957b6a8 100644
--- a/support/xstdio.h
+++ b/support/xstdio.h
@@ -27,6 +27,8 @@ __BEGIN_DECLS
FILE *xfopen (const char *path, const char *mode);
void xfclose (FILE *);
+ssize_t xgetline (char **lineptr, size_t *n, FILE *stream);
+
__END_DECLS
#endif /* SUPPORT_XSTDIO_H */