summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/lock-autospawn.c
diff options
context:
space:
mode:
authorMaarten Bosmans <mkbosmans@gmail.com>2011-01-05 19:50:44 +0100
committerMaarten Bosmans <mkbosmans@gmail.com>2011-02-17 12:02:31 +0100
commit821562b9bc8d1a9033daaae0fd5373498a085054 (patch)
treef134b67023b8ef5f100fab49fc924249f1f96bfa /src/pulsecore/lock-autospawn.c
parent30c7c9518440670ca3b627298c4e32885204882f (diff)
Use pa_read, pa_write and pa_poll instead of system functions
Diffstat (limited to 'src/pulsecore/lock-autospawn.c')
-rw-r--r--src/pulsecore/lock-autospawn.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/pulsecore/lock-autospawn.c b/src/pulsecore/lock-autospawn.c
index 1a082db6..a9c942fb 100644
--- a/src/pulsecore/lock-autospawn.c
+++ b/src/pulsecore/lock-autospawn.c
@@ -161,7 +161,7 @@ static void ping(void) {
for (;;) {
char x = 'x';
- if ((s = write(pipe_fd[1], &x, 1)) == 1)
+ if ((s = pa_write(pipe_fd[1], &x, 1, NULL)) == 1)
break;
pa_assert(s < 0);
@@ -188,7 +188,7 @@ static void wait_for_ping(void) {
if ((k = pa_poll(&pfd, 1, -1)) != 1) {
pa_assert(k < 0);
pa_assert(errno == EINTR);
- } else if ((s = read(pipe_fd[0], &x, 1)) != 1) {
+ } else if ((s = pa_read(pipe_fd[0], &x, 1, NULL)) != 1) {
pa_assert(s < 0);
pa_assert(errno == EAGAIN);
}
@@ -200,7 +200,7 @@ static void empty_pipe(void) {
pa_assert(pipe_fd[0] >= 0);
- if ((s = read(pipe_fd[0], &x, sizeof(x))) < 1) {
+ if ((s = pa_read(pipe_fd[0], &x, sizeof(x), NULL)) < 1) {
pa_assert(s < 0);
pa_assert(errno == EAGAIN);
}