X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=vss.c;h=8f177bab56b90a221f4ac84b73e4c54971df4a0c;hp=4a8aafa8d6e0c2ae239d09342ac10f3b08263828;hb=748d1368bc96dd7e1af879df1ea41b4d52842f7e;hpb=3150a0caa27a34d44556fb77f4a5aebc3d978580 diff --git a/vss.c b/vss.c index 4a8aafa8..8f177bab 100644 --- a/vss.c +++ b/vss.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 1997-2011 Andre Noll + * Copyright (C) 1997-2012 Andre Noll * * Licensed under the GPL v2. For licencing details see COPYING. */ @@ -26,10 +26,10 @@ #include "server.cmdline.h" #include "list.h" #include "send.h" +#include "sched.h" #include "vss.h" #include "ipc.h" #include "fd.h" -#include "sched.h" extern struct misc_meta_data *mmd; @@ -1136,7 +1136,7 @@ static void vss_post_select(struct sched *s, struct task *t) recv_afs_result(vsst, &s->rfds); else if (FD_ISSET(vsst->afs_socket, &s->wfds)) { PARA_NOTICE_LOG("requesting new fd from afs\n"); - ret = send_buffer(vsst->afs_socket, "new"); + ret = write_buffer(vsst->afs_socket, "new"); if (ret < 0) PARA_CRIT_LOG("%s\n", para_strerror(-ret)); else @@ -1157,11 +1157,12 @@ static void vss_post_select(struct sched *s, struct task *t) * Initialize the virtual streaming system task. * * \param afs_socket The fd for communication with afs. + * \param s The scheduler to register the vss task to. * * This also initializes all supported senders and starts streaming * if the --autoplay command line flag was given. */ -void init_vss_task(int afs_socket) +void init_vss_task(int afs_socket, struct sched *s) { static struct vss_task vss_task_struct, *vsst = &vss_task_struct; int i; @@ -1194,5 +1195,5 @@ void init_vss_task(int afs_socket) &vsst->data_send_barrier); } sprintf(vsst->task.status, "vss task"); - register_task(&vsst->task); + register_task(s, &vsst->task); }