aboutsummaryrefslogtreecommitdiffstats
path: root/mpm/python/usrp_mpm/bfrfs.py
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2017-12-05 16:38:37 -0800
committerMartin Braun <martin.braun@ettus.com>2017-12-22 15:05:58 -0800
commit58a096dbb661dfeaadad08264e18c57c121e846d (patch)
treea5b81a74ad57bbc02e81a6fb43ae0c950bc94f5d /mpm/python/usrp_mpm/bfrfs.py
parenta568e1d58c05fcacc40398d658b2cefdf72403f9 (diff)
downloaduhd-58a096dbb661dfeaadad08264e18c57c121e846d.tar.gz
uhd-58a096dbb661dfeaadad08264e18c57c121e846d.tar.bz2
uhd-58a096dbb661dfeaadad08264e18c57c121e846d.zip
mpm: bfrfs: Assert reference buffer is a byte string
Reviewed-By: Brent Stapleton <brent.stapleton@ettus.com>
Diffstat (limited to 'mpm/python/usrp_mpm/bfrfs.py')
-rw-r--r--mpm/python/usrp_mpm/bfrfs.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/mpm/python/usrp_mpm/bfrfs.py b/mpm/python/usrp_mpm/bfrfs.py
index 78930913d..7a673e4eb 100644
--- a/mpm/python/usrp_mpm/bfrfs.py
+++ b/mpm/python/usrp_mpm/bfrfs.py
@@ -80,6 +80,7 @@ class BufferFS(object):
def __init__(self, raw_data_buffer, max_size=None, alignment=None, log=None):
+ assert isinstance(raw_data_buffer, bytes)
self.max_size = len(raw_data_buffer) if max_size is None else max_size
self.raw_data_buffer = raw_data_buffer[:self.max_size]
self.alignment = alignment or DEFAULT_ALIGNMENT