[PATCH 5.4.y 3/3] Input: pegasus-notetaker - fix potential out-of-bounds access