Changeset 64:93c00fbc439a in roaraudio


Ignore:
Timestamp:
07/12/08 12:45:45 (16 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

changed some basic things to support sources

Location:
roard
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • roard/include/sources.h

    r0 r64  
    1111int sources_free (void); 
    1212 
     13int sources_set_client (int client); 
     14 
    1315int sources_add (char * driver, char * device, char * containe, char * options, int primary); 
    1416 
  • roard/roard.c

    r63 r64  
    8787 } 
    8888 
     89 if ( (g_self_client = clients_new()) == -1 ) { 
     90  ROAR_ERR("Can not create self client!"); 
     91  return 1; 
     92 } 
     93 
    8994 if ( sources_init() == -1 ) { 
    9095  ROAR_ERR("Can not init sources!"); 
     96  return 1; 
     97 } 
     98 
     99 if ( (sources_set_client(g_self_client)) == -1 ) { 
     100  ROAR_ERR("Can not init set source client!"); 
    91101  return 1; 
    92102 } 
     
    187197 
    188198 
    189  if ( (g_self_client = clients_new()) == -1 ) { 
    190   ROAR_ERR("Can not create self client!"); 
    191   return 1; 
    192  } 
    193  
    194199 clients_set_pid(g_self_client, getpid()); 
    195200 clients_get(g_self_client, &self); 
  • roard/sources.c

    r0 r64  
    88} 
    99 
     10int sources_set_client (int client) { 
     11 if ( client >= 0 ) { 
     12  g_source_client = client; 
     13  return 0; 
     14 } else { 
     15  return -1; 
     16 } 
     17} 
    1018 
    1119int sources_free (void) { 
Note: See TracChangeset for help on using the changeset viewer.