• Cherry Zhang's avatar
    misc/wasm: make sure value ref id is unique · 28f9b880
    Cherry Zhang authored
    For each Javascript object that returns to Go as a js.Value, we
    associate the ref id to it. But if this ref id is copied or
    inherited to other object, it would mess up the ref-object
    mapping.
    
    In storeValue, make sure the object is indeed the one we are
    storing. Otherwise allocate a new ref id.
    
    Fixes #26143.
    
    Change-Id: Ie60bb2f8d1533da1bbe6f46045866515ec2af5a9
    Reviewed-on: https://go-review.googlesource.com/121835
    Run-TryBot: Cherry Zhang <cherryyz@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarRichard Musiol <neelance@gmail.com>
    28f9b880
Name
Last commit
Last update
..
android Loading commit data...
arm Loading commit data...
cgo Loading commit data...
chrome/gophertool Loading commit data...
git Loading commit data...
ios Loading commit data...
linkcheck Loading commit data...
nacl Loading commit data...
sortac Loading commit data...
swig Loading commit data...
trace Loading commit data...
wasm Loading commit data...
benchcmp Loading commit data...
editors Loading commit data...