--- doc/diag.py | 5 ++++- src/aio/usock_posix.inc | 16 ++++++++++------ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/doc/diag.py b/doc/diag.py index e004431..3b01ba5 100755 --- a/doc/diag.py +++ b/doc/diag.py @@ -144,7 +144,10 @@ class Visitor(object): self.visit(cursor) def visit(self, cursor): - name = cursor.kind.name + try: + name = cursor.kind.name + except ValueError: + name = 'VERY_BAD_NAME' meth = getattr(self, 'enter_' + name, None) if meth is not None: res = meth(cursor) diff --git a/src/aio/usock_posix.inc b/src/aio/usock_posix.inc index 893105f..4cc559d 100644 --- a/src/aio/usock_posix.inc +++ b/src/aio/usock_posix.inc @@ -952,14 +952,18 @@ error: case NN_USOCK_STATE_CANCELLING: switch (src) { case NN_USOCK_SRC_TASK_STOP: - nn_assert (type == NN_WORKER_TASK_EXECUTE); - nn_worker_rm_fd (usock->worker, &usock->wfd); - usock->state = NN_USOCK_STATE_LISTENING; + switch (type) { + case NN_WORKER_TASK_EXECUTE: + nn_worker_rm_fd (usock->worker, &usock->wfd); + usock->state = NN_USOCK_STATE_LISTENING; - /* Notify the accepted socket that it was stopped. */ - nn_fsm_action (&usock->asock->fsm, NN_USOCK_ACTION_DONE); + /* Notify the accepted socket that it was stopped. */ + nn_fsm_action (&usock->asock->fsm, NN_USOCK_ACTION_DONE); - return; + return; + default: + nn_fsm_bad_action (usock->state, src, type); + } case NN_USOCK_SRC_FD: switch (type) { case NN_WORKER_FD_IN: -- 1.9.3 --=-EO4FVepgQKKccETcbB11 Content-Disposition: attachment; filename="0002-Fixed-uninstall-issues.-Mic.-cleanup.patch" Content-Type: text/x-patch; name="0002-Fixed-uninstall-issues.-Mic.-cleanup.patch"; charset="UTF-7" Content-Transfer-Encoding: 7bit