A BSR message indicates that a function in your program is about to read beyond the stack pointer.
A BSR message is commonly caused by a function returning a pointer to a local variable that has gone out of scope. If the caller attempts to use that variable, it can result in a BSR message. To keep the value valid after the called function returns, make such variables static.