Commit 5a169179 authored by Ziye Yang's avatar Ziye Yang Committed by Tomasz Zawadzki
Browse files

uring: fix the assert issue.



Revise the if case to avoid the assert issue.

Change-Id: I095f3d111423e17abaa1f951fe22efb3d2e851b7
Signed-off-by: default avatarZiye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8872


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Community-CI: Mellanox Build Bot
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
parent 250b2ba0
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -907,8 +907,8 @@ sock_uring_group_reap(struct spdk_uring_sock_group_impl *group, int max, int max
		switch (task->type) {
		case SPDK_SOCK_TASK_POLLIN:
			if ((status & POLLIN) == POLLIN) {
				if (sock->base.cb_fn != NULL) {
					assert(sock->pending_recv == false);
				if (sock->base.cb_fn != NULL &&
				    sock->pending_recv == false) {
					sock->pending_recv = true;
					TAILQ_INSERT_TAIL(&group->pending_recv, sock, link);
				}