Bugs item #1340420, was opened at 2005-10-28 01:29 Message generated for change (Comment added) made by derekc You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=642714&aid=1340420&group_id=105970
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: candle Group: v3.0 >Status: Pending >Resolution: Fixed Priority: 9 Submitted By: Riko Eksteen (rikoe) Assigned to: Derek (derekc) Summary: Able to generate custom actions with invalid types Initial Comment: When I enter a custom action with the following settings: <CustomAction Id="MyAction" Execute="immediate" BinaryKey="myfile.exe" Return="check" /> the compiler doesn't give an error and generates a row in the CustomAction table with a Type value of 0, which is obviously not valid. Similarly, when I use just the FileKey attribute, a custom action row with type 16 is the result. Shouldn't the compiler give a warning if a FileKey or BinaryKey attribute is used without accompanying attributes like ExeCommand or DllEntry? Alternatively the type of custom action should be picked up from the extension of the file. I havn't checked all the possible combinations, but it is also possible to only specify the Directory attribute and generate a type "16" custom action... ---------------------------------------------------------------------- >Comment By: Derek (derekc) Date: 2005-11-01 17:26 Message: Logged In: YES user_id=518766 Both issues should now be fixed. ---------------------------------------------------------------------- Comment By: Derek (derekc) Date: 2005-10-29 16:11 Message: Logged In: YES user_id=518766 This has already been fixed in WiX 2.0 - the code just hasn't been ported back to CVS yet. However, in WiX 3.0, the authoring above throws an exception: C:\temp\test.wxs(6) : error CNDL0048 : The CustomAction element's DllEntry, Error, ExeCommand, JScriptCall, Script, Valu e, or VBScriptCall attribute was not found; one of these is required. candle.exe : error CNDL0001 : Cannot set column 'Type' with value 0 because it is less than the minimum allowed value fo r this column, 1. Exception Type: System.InvalidOperationException Stack Trace: at Microsoft.Tools.WindowsInstallerXml.ColumnDefinition.ValidateValue(Object value) in c:\delivery\Dev\wix\src\wix\ColumnDefinition.cs:line 947 at Microsoft.Tools.WindowsInstallerXml.Field.set_Data(Object value) in c:\delivery\Dev\wix\src\wix\Field.cs:line 65 at Microsoft.Tools.WindowsInstallerXml.Row.set_Item(Int32 field, Object value) in c:\delivery\Dev\wix\src\wix\Row.cs:line 199 at Microsoft.Tools.WindowsInstallerXml.Compiler.ParseCustomActionElement(XmlNode node) in c:\delivery\Dev\wix\src\wix\Compiler.cs:line 2899 at Microsoft.Tools.WindowsInstallerXml.Compiler.ParseProductElement(XmlNode node) in c:\delivery\Dev\wix\src\wix\Compiler.cs:line 8807 at Microsoft.Tools.WindowsInstallerXml.Compiler.ParseWixElement(XmlNode node) in c:\delivery\Dev\wix\src\wix\Compiler.cs:line 12913 at Microsoft.Tools.WindowsInstallerXml.Compiler.Compile(XmlDocument source) in c:\delivery\Dev\wix\src\wix\Compiler.cs:line 224 at Microsoft.Tools.WindowsInstallerXml.Tools.Candle.Run(String[] args) in c:\delivery\Dev\wix\src\candle\candle.cs:line 264 This is due to much better validation of the column types in WiX 3.0 and it should be fixed. I believe this opens up an entirely new class of bugs of WiX 3.0 because creating invalid rows is now not possible. We will likely have to condition all the row creation logic off in the case of an error. I'm bumping up the priority because if this isn't fixed users are going to start seeing a lot of stack traces in WiX 3.0. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=642714&aid=1340420&group_id=105970 ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ WiX-devs mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wix-devs
