Two-instruction addition to the existing close-emission branch (prev != 0 && now == 0). Without the reset, the next entry inherits a stale HWM that could arm the trail spuriously on event 0 of the new trade. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>