rem: int32 kcookie; team_info kinfo; status_t rc = B_OK; status_t rc2;  if ((addr)cookie >= KERNEL_BASE && (addr)cookie <= KERNEL_TOP) return ERR_VM_BAD_USER_MEMORY; if ((addr)info >= KERNEL_BASE && (addr)info <= KERNEL_TOP) return ERR_VM_BAD_USER_MEMORY;  rc2 = user_memcpy(&kcookie, cookie, sizeof(int32)); if (rc2 < 0) return rc2;  rc = _get_next_team_info(&kcookie, &kinfo, sizeof(team_info)); if (rc != B_OK) return rc;  rc2 = user_memcpy(cookie, &kcookie, sizeof(int32)); if (rc2 < 0) return rc2;  rc2 = user_memcpy(info, &kinfo, sizeof(team_info)); if (rc2 < 0) return rc2;  return rc;
add: status_t status; team_info info; int32 cookie;  if (!CHECK_USER_ADDRESS(userCookie) || !CHECK_USER_ADDRESS(userInfo) || user_memcpy(&cookie, userCookie, sizeof(int32)) < B_OK) return B_BAD_ADDRESS;  status = _get_next_team_info(&cookie, &info, sizeof(team_info)); if (status != B_OK) return status;  if (user_memcpy(userCookie, &cookie, sizeof(int32)) < B_OK || user_memcpy(userInfo, &info, sizeof(team_info)) < B_OK) return B_BAD_ADDRESS;  return status;
context: user_get_next_team_info(int32 *cookie, team_info *info){	int32 kcookie;	team_info kinfo;	status_t rc = B_OK;	status_t rc2;		if ((addr)cookie >= KERNEL_BASE && (addr)cookie <= KERNEL_TOP)		return ERR_VM_BAD_USER_MEMORY;	if ((addr)info >= KERNEL_BASE && (addr)info <= KERNEL_TOP)		return ERR_VM_BAD_USER_MEMORY;		rc2 = user_memcpy(&kcookie, cookie, sizeof(int32));	if (rc2 < 0)		return rc2;		rc = _get_next_team_info(&kcookie, &kinfo, sizeof(team_info));	if (rc != B_OK)		return rc;		rc2 = user_memcpy(cookie, &kcookie, sizeof(int32));	if (rc2 < 0)		return rc2;		rc2 = user_memcpy(info, &kinfo, sizeof(team_info));	if (rc2 < 0)		return rc2;		return rc;}