Moved note buffer implementation to notes.c