gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] /srv/bzr/gnash/avm2 r9589: Implement SETSLOT opcode.


From: Tom Stellard
Subject: [Gnash-commit] /srv/bzr/gnash/avm2 r9589: Implement SETSLOT opcode.
Date: Sun, 05 Oct 2008 20:04:25 +0800
User-agent: Bazaar (1.5)

------------------------------------------------------------
revno: 9589
committer: Tom Stellard <address@hidden>
branch nick: gnash_dev
timestamp: Sun 2008-10-05 20:04:25 +0800
message:
  Implement SETSLOT opcode.
modified:
  libcore/vm/Machine.cpp
=== modified file 'libcore/vm/Machine.cpp'
--- a/libcore/vm/Machine.cpp    2008-10-05 00:14:40 +0000
+++ b/libcore/vm/Machine.cpp    2008-10-05 12:04:25 +0000
@@ -1653,7 +1653,11 @@
                boost::uint32_t sindex = mStream->read_V32();
                as_value value = pop_stack();
                as_value object = pop_stack();
-               LOG_DEBUG_AVM("We should be setting the property at slot 
%u",sindex);
+               //We use sindex + 1, because currently as_object sets a 
property at a slot index
+               //1 higher than the index the abc_block thinks the property is 
at.
+               if(!object.to_object().get()->set_member_slot(sindex+1,value)){
+                       LOG_DEBUG_AVM("Failed to set property at real_slot=%u 
abc_slot=%u",sindex+1,sindex);
+               }
                //TODO: Actually set the object's value.
                break;
        }


reply via email to

[Prev in Thread] Current Thread [Next in Thread]