From 55baff4c9bcbc001cbb8972c289ebfa356d4665b Mon Sep 17 00:00:00 2001 From: Damien George Date: Tue, 21 Jan 2014 21:40:13 +0000 Subject: Revamp qstrs: they now include length and hash. Can now have null bytes in strings. Can define ROM qstrs per port using qstrdefsport.h --- py/objexcept.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'py/objexcept.c') diff --git a/py/objexcept.c b/py/objexcept.c index 2e145ee358..c91b71dd9e 100644 --- a/py/objexcept.c +++ b/py/objexcept.c @@ -7,7 +7,7 @@ #include "nlr.h" #include "misc.h" #include "mpconfig.h" -#include "mpqstr.h" +#include "qstr.h" #include "obj.h" #include "objtuple.h" @@ -100,7 +100,7 @@ mp_obj_t mp_obj_new_exception_msg_varg(qstr id, const char *fmt, ...) { va_start(ap, fmt); vstr_vprintf(vstr, fmt, ap); va_end(ap); - o->msg = qstr_from_str_take(vstr->buf, vstr->alloc); + o->msg = qstr_from_strn_take(vstr->buf, vstr->alloc, vstr->len); } return o; -- cgit v1.2.3