Re: relayd: Remove rcsocks

Kirill A. Korinsky <[email protected]>
Newsgroups gmane.os.openbsd.tech
Message-ID <[email protected]>
On Wed, 01 Jul 2026 14:21:13 +0200,
Martijn van Duren <[email protected]> wrote:
> 
> Similar to vmd, ps_rcsocks isn't used by relayd. I suggest we remove it
> here as well.
> 
> OK?
>

OK kirill@

> martijn@
> 
> diff d010102fe4efde3ee95164581695909c7c6b672a c42669961b0f5552b7292657a7b6940f15b7b7ae
> commit - d010102fe4efde3ee95164581695909c7c6b672a
> commit + c42669961b0f5552b7292657a7b6940f15b7b7ae
> blob - 72d1fdfaf1abd1be8b35cfb93c5dd541ab4aa7d4
> blob + 5f9bcbf84bbd328a9bfc717cd79d933ccb3938d4
> --- usr.sbin/relayd/proc.c
> +++ usr.sbin/relayd/proc.c
> @@ -517,16 +517,12 @@ proc_run(struct privsep *ps, struct privsep_proc *p,
>  {
>  	struct passwd		*pw;
>  	const char		*root;
> -	struct control_sock	*rcs;
>  
>  	log_procinit(p->p_title);
>  
>  	if (p->p_id == PROC_CONTROL && ps->ps_instance == 0) {
>  		if (control_init(ps, &ps->ps_csock) == -1)
>  			fatalx("%s: control_init", __func__);
> -		TAILQ_FOREACH(rcs, &ps->ps_rcsocks, cs_entry)
> -			if (control_init(ps, rcs) == -1)
> -				fatalx("%s: control_init", __func__);
>  	}
>  
>  	/* Use non-standard user */
> @@ -576,9 +572,6 @@ proc_run(struct privsep *ps, struct privsep_proc *p,
>  	if (p->p_id == PROC_CONTROL && ps->ps_instance == 0) {
>  		if (control_listen(&ps->ps_csock) == -1)
>  			fatalx("%s: control_listen", __func__);
> -		TAILQ_FOREACH(rcs, &ps->ps_rcsocks, cs_entry)
> -			if (control_listen(rcs) == -1)
> -				fatalx("%s: control_listen", __func__);
>  	}
>  
>  	DPRINTF("%s: %s %d/%d, pid %d", __func__, p->p_title,
> blob - ba74a1fe48f19a2c50882d537c366152a434cb2f
> blob + efb1708e03d8eff6a62a2cb125a02518911710a5
> --- usr.sbin/relayd/relayd.c
> +++ usr.sbin/relayd/relayd.c
> @@ -183,7 +183,6 @@ main(int argc, char *argv[])
>  	relayd_env = env;
>  	env->sc_ps = ps;
>  	ps->ps_env = env;
> -	TAILQ_INIT(&ps->ps_rcsocks);
>  	env->sc_conffile = conffile;
>  	env->sc_conf.opts = opts;
>  	TAILQ_INIT(&env->sc_hosts);
> blob - 01472db8a564dbe6bc1b952b7477bb34f30c1e3e
> blob + 1bdaedf6d3374b06423a3a7d7ba9f9ef4be83a73
> --- usr.sbin/relayd/relayd.h
> +++ usr.sbin/relayd/relayd.h
> @@ -1036,7 +1036,6 @@ struct privsep {
>  	u_int				 ps_instance;
>  
>  	struct control_sock		 ps_csock;
> -	struct control_socks		 ps_rcsocks;
>  
>  	/* Event and signal handlers */
>  	struct event			 ps_evsigint;
> 

-- 
wbr, Kirill
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.