From 2644dff68f07d9bf27bf3a1c7936e48aae282fac Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Wed, 6 Mar 1996 23:10:30 +0000 Subject: (pager_change_attributes): Correctly remove AR from P's linked list of attribute change requests. --- libpager/pager-attr.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'libpager/pager-attr.c') diff --git a/libpager/pager-attr.c b/libpager/pager-attr.c index 762bb971..cbc1533f 100644 --- a/libpager/pager-attr.c +++ b/libpager/pager-attr.c @@ -1,5 +1,5 @@ /* Changing pager attributes synchronously - Copyright (C) 1994 Free Software Foundation + Copyright (C) 1994, 1996 Free Software Foundation This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as @@ -84,9 +84,12 @@ pager_change_attributes (struct pager *p, { while (ar->attrs_pending) condition_wait (&p->wakeup, &p->interlock); - if (!--ar->threads_waiting) + + if (! --ar->threads_waiting) { *ar->prevp = ar->next; + if (ar->next) + ar->next->prevp = ar->prevp; free (ar); } } -- cgit v1.2.3