listener.h 642 Bytes
Newer Older
Benoit Steiner's avatar
Benoit Steiner committed
1 2 3 4 5 6 7 8
/* VideoLAN VLANbridge: Listener module
 *
 * Definition file
 *
 * You need to include <pthread.h> before including this file
 */


Benoit Steiner's avatar
Benoit Steiner committed
9 10 11 12 13 14
#ifndef _LISTENER_H
#define _LISTENER_H



struct s_Listener
Benoit Steiner's avatar
Benoit Steiner committed
15 16
{
  /* thread id */
Benoit Steiner's avatar
Benoit Steiner committed
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
  pthread_t tid;

  /* Handle the alone sockfd used to communicate with the VLANserver */
  int iSockFd;

  /* Signal used to wake up the listener when the bridge is connected to VLANserver */
  pthread_cond_t WakeUpSignal;
};


int InitListener (struct s_Listener* pslListener);
void* ListenerThread (void* pvArg);
int CancelListener (struct s_Listener* pslListener);
int FreeListener (struct s_Listener* pslListener);

#endif