Originally posted by [b]theultramage[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=3410
As was demonstrated by
bug #1886: Negative @heal With Large Number Causes Crash, there is an implementation defect in the status_heal/status_damage code, where doing @heal -2147483648 (INT_MIN) will cause an infinite loop. The reason being that -INT_MIN == INT_MIN.
There are existing attempts to patch this. In
r13321, checks to @heal were added. However that apparently wasn't enough to stop silly GMs from crashing still (maybe some other command?), and so in
r13955 an attempt was made to stop this infinite loop directly in status heal/damage code. But again, due to an implementation mistake, nothing was fixed.
I propose the following:
1. examine the code to see which parts rely on the damage<->heal value inversion behavior
2. rewrite those places to call the proper function
3. get rid of the recursive logic