int dagstream;
int dagfd;
- /* Try all the DAGs 0-9 */
- for (c = 0; c < 9; c++) {
+ /* Try all the DAGs 0-31 */
+ for (c = 0; c < 32; c++) {
snprintf(name, 12, "dag%d", c);
if (-1 == dag_parse_name(name, dagname, DAGNAME_BUFSIZE, &dagstream))
{
{
int stream, rxstreams;
rxstreams = dag_rx_get_stream_count(dagfd);
- for(stream=0;stream<16;stream+=2) {
+ for(stream=0;stream<DAG_STREAM_MAX;stream+=2) {
if (0 == dag_attach_stream(dagfd, stream, 0, 0)) {
dag_detach_stream(dagfd, stream);
*/
ret = -1;
}
+
+ rxstreams--;
+ if(rxstreams <= 0) {
+ break;
+ }
}
}
}