newrelic / video-agent-roku

New Relic Agent for Roku
Apache License 2.0
18 stars 18 forks source link

`NewRelicWait()` infinite loop #6

Closed timalacey closed 4 years ago

timalacey commented 4 years ago

https://github.com/newrelic/video-agent-roku/blob/49b7faa95c0bb61c9edcbc588ed06669492fe351/source/newrelic/NRAgent.brs#L50

There is no way to exit this loop and finish running NewRelicWait(). Reaching the end of main() is the only way to safely exit a Brightscript application without a crash being reported.

timalacey commented 4 years ago
if nrProcessMessage(msg) = false
    'handle message manually
    res = foo(msg)
    if res = false then return
end if

or something similar should suffice

asllop commented 4 years ago

Fixed in https://github.com/newrelic/video-agent-roku/commit/d0e7d1aff1dfeeedbdd91f276a535dd3c75acdc1