bug fix in sundials structural event handling