summaryrefslogtreecommitdiffstatshomepage
path: root/py/objstr.c
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-04-19 03:09:17 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-04-19 03:21:06 +0300
commit504e23388ce68fcb1ac80a7c411979718686af7c (patch)
treebe71de29c97d78d22423b8685672c59684096f5a /py/objstr.c
parent4602b9a79f86176d31bf8d3760abf2d39a380b39 (diff)
downloadmicropython-504e23388ce68fcb1ac80a7c411979718686af7c.tar.gz
micropython-504e23388ce68fcb1ac80a7c411979718686af7c.zip
objstr: Init hash in mp_obj_str_builder_start() to 0.
Diffstat (limited to 'py/objstr.c')
-rw-r--r--py/objstr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/py/objstr.c b/py/objstr.c
index a682144b8f..b0d5cba6f1 100644
--- a/py/objstr.c
+++ b/py/objstr.c
@@ -1415,6 +1415,7 @@ mp_obj_t mp_obj_str_builder_start(const mp_obj_type_t *type, uint len, byte **da
mp_obj_str_t *o = m_new_obj(mp_obj_str_t);
o->base.type = type;
o->len = len;
+ o->hash = 0;
byte *p = m_new(byte, len + 1);
o->data = p;
*data = p;