Author: eb
Date: 2007-05-30 13:19:35 -0600 (Wed, 30 May 2007)
New Revision: 5576
Modified:
gnuradio/trunk/usrp/host/lib/legacy/usrp_basic.cc
Log:
Dave Gotwisner's fix for usrp_basic_rx::stop
Modified: gnuradio/trunk/usrp/host/lib/legacy/usrp_basic.cc
===================================================================
--- gnuradio/trunk/usrp/host/lib/legacy/usrp_basic.cc 2007-05-30 18:14:59 UTC
(rev 5575)
+++ gnuradio/trunk/usrp/host/lib/legacy/usrp_basic.cc 2007-05-30 19:19:35 UTC
(rev 5576)
@@ -541,17 +541,19 @@
{
bool ok = usrp_basic::stop();
- if (!d_ephandle->stop()){
- fprintf (stderr, "usrp_basic_rx: failed to stop end point streaming");
+ if (!set_rx_enable(false)){
+ fprintf (stderr, "usrp_basic_rx: set_rx_enable(false) failed\n");
usb_strerror ();
ok = false;
}
- if (!set_rx_enable(false)){
- fprintf (stderr, "usrp_basic_rx: set_rx_enable(false) failed\n");
+
+ if (!d_ephandle->stop()){
+ fprintf (stderr, "usrp_basic_rx: failed to stop end point streaming");
usb_strerror ();
ok = false;
}
- return false;
+
+ return ok;
}
usrp_basic_rx *
@@ -970,16 +972,18 @@
{
bool ok = usrp_basic::stop ();
- if (!set_tx_enable (false)){
- fprintf (stderr, "usrp_basic_tx: set_tx_enable(false) failed\n");
+ if (!d_ephandle->stop ()){
+ fprintf (stderr, "usrp_basic_tx: failed to stop end point streaming");
usb_strerror ();
ok = false;
}
- if (!d_ephandle->stop ()){
- fprintf (stderr, "usrp_basic_tx: failed to stop end point streaming");
+
+ if (!set_tx_enable (false)){
+ fprintf (stderr, "usrp_basic_tx: set_tx_enable(false) failed\n");
usb_strerror ();
ok = false;
}
+
return ok;
}
_______________________________________________
Commit-gnuradio mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/commit-gnuradio