Remove small bugs in example and GenFsm code