GNOME Bugzilla – Bug 702911
Creating a soup server on an already bound port in gjs silently returns the wrong object
Last modified: 2013-06-28 12:37:55 UTC
>>> Soup = gi.imports.Soup >>> s1 = new Soup.Server({"port": 10011}) [object instance proxy GIName:Soup.Server jsobj@0x7f2869850fa0 native@0x461ff10] >>> s2 = new Soup.Server({"port": 10011}) [object prototype of GIName:Soup.Server jsobj@0x7f2869bc7910] ^^^^^^^^^ I would expect it to throw an exception.
yeah, SoupServer is a broken old API that sometimes returns NULL from its constructor(), which you're not supposed to do, and apparently gjs doesn't deal with this. Will be fixed eventually... *** This bug has been marked as a duplicate of bug 561547 ***