Changeset 5149:b7345c9daac1 in roaraudio for roarclients/roarctl.c
- Timestamp:
- 10/15/11 15:24:11 (13 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
roarclients/roarctl.c
r5144 r5149 66 66 " --verbose -v - Show verbose output\n" 67 67 " --list-aiprofiles - Show audio info profiles and exit\n" 68 " --list-libstandards - Gets list of library (libroar) supported standards\n" 68 69 " --enum-servers - Show a list of possible servers\n" 69 70 ); … … 128 129 "\n" 129 130 " serverstandards - Gets list of server supported standards\n" 131 " libstandards - Gets list of library (libroar) supported standards\n" 130 132 "\n" 131 133 " listclients - Gets Information about clients\n" … … 295 297 } 296 298 297 void server_standards (struct roar_connection * con) { 298 struct roar_stds * stds; 299 static void print_stds (const struct roar_stds * stds) { 299 300 size_t i; 300 301 int vendor, standard, version; 301 302 char numbuf[2][8]; 302 303 const char * vendor_name; 303 304 if ( roar_caps_stds(con, &stds, NULL, -1) == -1 ) {305 fprintf(stderr, "Error: can not get server standards\n");306 return;307 }308 304 309 305 for (i = 0; i < stds->stds_len; i++) { … … 327 323 printf("Server standard : %s-%i%s\n", vendor_name, standard, numbuf[1]); 328 324 } 325 } 326 327 void server_standards (struct roar_connection * con) { 328 struct roar_stds * stds; 329 330 if ( roar_caps_stds(con, &stds, NULL, -1) == -1 ) { 331 fprintf(stderr, "Error: can not get server standards\n"); 332 return; 333 } 334 335 print_stds(stds); 336 337 roar_stds_free(stds); 338 } 339 340 void lib_standards (void) { 341 print_stds(libroar_libstds()); 329 342 } 330 343 … … 1083 1096 list_aiprofiles(); 1084 1097 return 0; 1098 } else if ( strcmp(k, "--list-libstandards") == 0 ) { 1099 lib_standards(); 1100 return 0; 1085 1101 } else if ( strcmp(k, "--enum-servers") == 0 ) { 1086 1102 enum_servers(); … … 1186 1202 } else if ( !strcmp(k, "serverstandards") ) { 1187 1203 server_standards(&con); 1204 } else if ( !strcmp(k, "libstandards") ) { 1205 lib_standards(); 1188 1206 } else if ( !strcmp(k, "listclients") ) { 1189 1207 list_clients(&con);
Note: See TracChangeset
for help on using the changeset viewer.