Opened 7 years ago
Last modified 4 years ago
#4630 new defect
GetTechModifiedProperty don't handle multiplication or addition by 0
Reported by: | fatherbushido | Owned by: | |
---|---|---|---|
Priority: | Should Have | Milestone: | Backlog |
Component: | Simulation | Keywords: | |
Cc: | Patch: |
Description (last modified by )
In GetTechModifiedProperty (globalscripts), there are checks for "multiply" or "add" key. But when the value is 0, we fall in the case which throw an error. I don't know if that's a good idea or not to allow multiplication by 0 and addition of 0, (the first can be replaced by "replace": 0, and the second is useless) so that can be close at won't fix.
Change History (6)
comment:1 by , 7 years ago
Description: | modified (diff) |
---|
comment:3 by , 5 years ago
Component: | UI & Simulation → Simulation |
---|
Move tickets to Simulation
as UI & Simulation
got some sub components.
comment:5 by , 4 years ago
Trac notified me so I looked at that thing I had forgotten. I wonder if the report of 3 years ago was good because the comment:2 of two years ago said it worked. Or did the comment:2 of two years ago didn't refer to the reported bug of three years ago?
It seems also that the reported bug in the forum linked on the phabricator reported linked in the comment:4 is adressing another - yet related - issue and is also another issue for a part of the code which didn't even exist at the time of that trac report.
comment:6 by , 4 years ago
yes comment 2 looks unrelated, i guess i got confused at that time by usage add and mull in templates
I just used <.. op="mul">0</..> and <... op="add">0</..> and it worked. first time result was 0 and second time value non touched and no errors