From b51fdc221de23a1a01a7143e381b35a38371ad8e Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Fri, 7 Nov 2008 02:22:34 +0000 Subject: wrap do/while construct around the function macro SESSRELE(); ok dlg --- sys/sys/proc.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sys') diff --git a/sys/sys/proc.h b/sys/sys/proc.h index cbea6649d1c..da083ee9377 100644 --- a/sys/sys/proc.h +++ b/sys/sys/proc.h @@ -1,4 +1,4 @@ -/* $OpenBSD: proc.h,v 1.109 2008/11/01 05:59:20 deraadt Exp $ */ +/* $OpenBSD: proc.h,v 1.110 2008/11/07 02:22:33 deraadt Exp $ */ /* $NetBSD: proc.h,v 1.44 1996/04/22 01:23:21 christos Exp $ */ /*- @@ -353,10 +353,10 @@ struct uidinfo *uid_find(uid_t); #define SESS_LEADER(p) ((p)->p_session->s_leader == (p)) #define SESSHOLD(s) ((s)->s_count++) -#define SESSRELE(s) { \ +#define SESSRELE(s) do { \ if (--(s)->s_count == 0) \ - pool_put(&session_pool, s); \ -} + pool_put(&session_pool, (s)); \ +} while (/* CONSTCOND */ 0) /* * Flags to fork1(). -- cgit v1.2.3