diff options
author | Martin Braun <martin.braun@ettus.com> | 2019-07-01 16:17:09 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2019-07-20 14:41:00 -0700 |
commit | 2cba1407059049dfbcdb4bf164967aa62e9ee32a (patch) | |
tree | 16d0896c69c81ab4acad6670c55db0be2cb23dc1 | |
parent | e8b3319531771ad40a4bd9fba4fbd7acb8397f48 (diff) | |
download | uhd-2cba1407059049dfbcdb4bf164967aa62e9ee32a.tar.gz uhd-2cba1407059049dfbcdb4bf164967aa62e9ee32a.tar.bz2 uhd-2cba1407059049dfbcdb4bf164967aa62e9ee32a.zip |
converters: Improve exception string for illegal formats
When trying to create a converter with an illegal string, it will now
look like this:
[convert] Cannot find an item size for: `???'
-rw-r--r-- | host/lib/convert/convert_impl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/host/lib/convert/convert_impl.cpp b/host/lib/convert/convert_impl.cpp index 99c1bf3c1..6385965f0 100644 --- a/host/lib/convert/convert_impl.cpp +++ b/host/lib/convert/convert_impl.cpp @@ -135,7 +135,7 @@ size_t convert::get_bytes_per_item(const std::string &format){ return get_bytes_per_item(format.substr(0, pos)); } - throw uhd::key_error("Cannot find an item size:\n" + format); + throw uhd::key_error("[convert] Cannot find an item size for: `" + format + "'"); } UHD_STATIC_BLOCK(convert_register_item_sizes){ |