Changeset 4432:d2ded197053f in roaraudio


Ignore:
Timestamp:
10/09/10 14:44:14 (8 years ago)
Author:
phi
Branch:
default
Message:

very basic support for serverinfo

File:
1 edited

Legend:

Unmodified
Added
Removed
  • roarclients/roarctl.c

    r4413 r4432  
    201201#endif 
    202202 
     203void server_info (struct roar_connection * con) { 
     204 struct roar_server_info * info = roar_server_info(con); 
     205 
     206 if ( info == NULL ) { 
     207  fprintf(stderr, "Error: can not get server info\n"); 
     208  return; 
     209 } 
     210 
     211 if ( info->version != NULL ) 
     212  printf("Stream version        : %s\n", info->version); 
     213 
     214 roar_server_info_free(info); 
     215} 
     216 
    203217void server_oinfo (struct roar_connection * con) { 
    204218 struct roar_stream s; 
     
    10651079  } else if ( !strcmp(k, "whoami") ) { 
    10661080   printf("My client ID is: %i\n", roar_get_clientid(&con)); 
     1081  } else if ( !strcmp(k, "serverinfo") ) { 
     1082   server_info(&con); 
    10671083  } else if ( !strcmp(k, "serveroinfo") ) { 
    10681084   server_oinfo(&con); 
Note: See TracChangeset for help on using the changeset viewer.