diff options
author | Philip Balister <philip@opensdr.com> | 2011-02-25 06:52:01 -0800 |
---|---|---|
committer | Philip Balister <philip@opensdr.com> | 2011-02-25 06:52:59 -0800 |
commit | a675b9d8d0ee0f23f59bd6426cf42ed673a26c50 (patch) | |
tree | fce83498f9ffd4a0ad1bb354d32f0d1f37b54fda /host/usrp_e_utils | |
parent | aee2a4e52e7a2b9dcb60d1d34f59f7f8f80e7f86 (diff) | |
download | uhd-a675b9d8d0ee0f23f59bd6426cf42ed673a26c50.tar.gz uhd-a675b9d8d0ee0f23f59bd6426cf42ed673a26c50.tar.bz2 uhd-a675b9d8d0ee0f23f59bd6426cf42ed673a26c50.zip |
usrp_e : Prevent people from typing in large numbers that crash the
test.
Diffstat (limited to 'host/usrp_e_utils')
-rw-r--r-- | host/usrp_e_utils/usrp-e-loopback.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/host/usrp_e_utils/usrp-e-loopback.c b/host/usrp_e_utils/usrp-e-loopback.c index a63882475..78e2b5d16 100644 --- a/host/usrp_e_utils/usrp-e-loopback.c +++ b/host/usrp_e_utils/usrp-e-loopback.c @@ -212,6 +212,11 @@ int main(int argc, char *argv[]) packet_data_length = atoi(argv[1]); + if (packet_data_length > 1016) { + packet_data_length = 1016; + printf("Max data length = 1016, clamping.\n"); + } + fp = open("/dev/usrp_e0", O_RDWR); printf("fp = %d\n", fp); |