Handle invalid opcode gracefully