Changeset 2524:fb139fa9dfb9 in roaraudio
- Timestamp:
- 09/01/09 17:55:04 (15 years ago)
- Branch:
- default
- Phase:
- public
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/roard/protocol-esound.c
r2522 r2524 66 66 }; 67 67 68 // command handling: 68 69 int emul_esd_exec_command(int client, int cmd, struct roar_vio_calls * vio) { 69 70 struct emul_esd_command * cur; … … 132 133 } 133 134 135 // porto lib: 136 int emul_esd_int_read (int client, int * data, struct roar_vio_calls * vio) { 137 _cmd_t d; 138 139 if ( data == NULL ) 140 return -1; 141 142 if ( roar_vio_read(vio, &d, _INTSIZE) != _INTSIZE ) 143 return -1; 144 145 *data = d; 146 147 return 0; 148 } 149 150 int emul_esd_int_write (int client, int data, struct roar_vio_calls * vio) { 151 _cmd_t d = data; 152 153 return roar_vio_write(vio, &d, _INTSIZE) == _INTSIZE ? 0 : -1; 154 } 155 156 int emul_esd_test_auth (int client, void * data, struct roar_vio_calls * vio) { 157 // accept all clients for the moment. 158 return emul_esd_int_write(client, 1, vio); 159 } 160 161 int emul_esd_test_byteorder(int client, void * data, struct roar_vio_calls * vio) { 162 // TODO: do a real test 163 return 0; 164 } 165 166 // handler: 167 int emul_esd_on_connect (int client, struct emul_esd_command * cmd, void * data, struct roar_vio_calls * vio) { 168 return -1; 169 } 170 171 134 172 #endif 135 173 #endif -
roard/include/emul_esd.h.OLD
r2522 r2524 42 42 }; 43 43 44 int emul_esd_exec_command(int client, int cmd, struct roar_vio_calls * vio); 45 int emul_esd_check_client(int client, struct roar_vio_calls * vio); 44 int emul_esd_exec_command (int client, int cmd, struct roar_vio_calls * vio); 45 int emul_esd_check_client (int client, struct roar_vio_calls * vio); 46 47 int emul_esd_int_read (int client, int * data, struct roar_vio_calls * vio); 48 int emul_esd_int_write (int client, int data, struct roar_vio_calls * vio); 49 int emul_esd_test_auth (int client, void * data, struct roar_vio_calls * vio); 50 int emul_esd_test_byteorder(int client, void * data, struct roar_vio_calls * vio); 51 52 int emul_esd_on_connect (int client, struct emul_esd_command * cmd, void * data, struct roar_vio_calls * vio); 46 53 47 54 #endif
Note: See TracChangeset
for help on using the changeset viewer.