Fix a few bugs

- Misuse clearTimeout with setInterval
- Set timeout for safety
- Avoid double calling captureGifAnimationAbort from content