JPEXS Free Flash Decompiler Issue Tracker

If you are looking for the decompiler itself, visit https://github.com/jindrapetrik/jpexs-decompiler

NEW : We have got a new blog where we post some interesting SWF internals info.

List of issuesList of issues

#2142 Weird bug with PackageNamespace("") after swf XML edit
Author: user dimusLV
Date created:
Type: bug
Visibility: Everybody
Assigned to:
Labels: XML
State: upgraded Help

> What steps will reproduce the problem? What is the expected output? What do you see instead? Open snap36.swf, go to the Configurable class and notice many of the public static vars having initial values. Now start editing the p-code of the class initializer, add and delete a space and save the p-code: suddenly almost all the initial values disappear. (Only the ones that have an initial value set in the specific trait p-code remain.) After looking into this a bit further, it seems like editing any script with PackageNamespace("") creates a new namespace that's seemingly the same PackageNamespace(""), but the name string id is 8339 instead of 1, which links to a different empty string. From looking at the diff in swf.xml after editing the Configurable class initializer (which I've linked below), it seems like it creates a second set of multinames for all the public static vars in Configurable with the new namespace. Also, if you do the same procedure on snap36_old.swf, it seems like nothing out of the ordinary happens. The new version was acquired by exporting the swf.xml of the old version, editing it a bit to basically move various asset classes to a different folder and then importing the edited XML, which I've also linked below. Also, it seems like the .swf still works just fine after these changes, but I would still prefer to avoid them. > What version of the product are you using? Is it "nightly build"? Which operating system do you have? I'm using stable version 20.0.0 on Windows 10. > Please provide any additional information below. If the problem is related to a SWF file, attach it here, otherwise we can't help you.
Downloadsnap36.swf (6,263 KiB)Downloadsnap36_old.swf (6,264 KiB)Downloadswfnew2.xml (28,151 KiB)Downloaddiff.png (133 KiB)
user
I guess there's a simpler way to reproduce the bug: - open snap36_old.swf, edit(add a space, delete it and save) the Configurable class initializer p-code and notice nothing weird happens - export the swf.xml of snap36_old.swf, import it, save it as a new .swf and reload it - now the weird bug happens(editing the p-code of the Configurable class initializer makes the initial values seemingly disappear/creates a new PackageNamespace(""))
admin
This is fixed in nightly 2732. The XML exporter incorrectly saved string values containing only spaces as empty string. Now it should work okay. The "snap36.swf" swf is corrupted, please use the XML export / import from "snap36_old" again.
State: new→upgraded