gnash-commit
[Top][All Lists]
Advanced

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

Re: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_fi


From: Benjamin Wolsey
Subject: Re: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-1634-g404343a
Date: Fri, 05 Jul 2013 13:05:00 +0200

> commit 404343a510a88352b465ae37026102cd1df705e0
> Author: Sandro Santilli <address@hidden>
> Date:   Wed Jul 3 09:10:04 2013 +0200
> 
>     Initialize NetStream prototype only once
> 
> diff --git a/libcore/asobj/NetStream_as.cpp b/libcore/asobj/NetStream_as.cpp
> index b915df9..034e85c 100644
> --- a/libcore/asobj/NetStream_as.cpp
> +++ b/libcore/asobj/NetStream_as.cpp
> @@ -1590,11 +1590,13 @@ netstream_new(const fn_call& fn)
>          if (isNativeType(toObject(fn.arg(0), getVM(fn)), nc)) {
>              ns->setNetCon(nc);
>              if ( nc->isConnected() ) {
> -                // TODO: initialize only once ?
> -                // Test it (but keep re-entrancy, in case)
> -                as_object* proto = obj->get_prototype();
> -                if ( proto ) {
> -                    attachPrototypeProperties(*proto);
> +                static as_object* proto = NULL;

This is rather a shame; it took a long time to get rid of all the
statics so that multiple or successive VMs would work. Even some kind of
isNetstreamInitialized flag in the VM would be better than that.

Ben

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

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