Defining an action without a button index caused a segfault since
the parser was treating it as the close of a previously opened action
block. This makes the parser use button LEFT as a fallback.
Also ensure that an action block has been opened before
attempting to close the block.
Fixesjaagr/lemonbuddy#104