Index | Thread | Search

From:
Mike Larkin <mlarkin@nested.page>
Subject:
Re: vmd: use imsg_get_fd
To:
tech@openbsd.org
Date:
Tue, 22 Oct 2024 20:16:31 -0700

Download raw body.

Thread
On Tue, Oct 22, 2024 at 04:44:22PM +0200, Claudio Jeker wrote:
> Do not access imsg->fd instead use imsg_get_fd() like the rest of vmd.


not sure if this was already done but ok mlarkin

>
> --
> :wq Claudio
>
> Index: vmm.c
> ===================================================================
> RCS file: /cvs/src/usr.sbin/vmd/vmm.c,v
> diff -u -p -r1.123 vmm.c
> --- vmm.c	26 Sep 2024 01:45:13 -0000	1.123
> +++ vmm.c	22 Oct 2024 14:43:07 -0000
> @@ -318,7 +318,7 @@ vmm_dispatch_parent(int fd, struct privs
>  	case IMSG_VMDOP_RECEIVE_PSP_FD:
>  		if (env->vmd_psp_fd > -1)
>  			fatalx("already received psp fd");
> -		env->vmd_psp_fd = imsg->fd;
> +		env->vmd_psp_fd = imsg_get_fd(imsg);
>  		break;
>  	default:
>  		return (-1);
>