From 34ca95e22a69a7be91133c06c7e03a794bd50c5d Mon Sep 17 00:00:00 2001 From: Ted Lemon Date: Sat, 1 Jul 2000 05:54:22 +0000 Subject: Fix test condition for class billing in supersede_lease --- common/memory.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/common/memory.c b/common/memory.c index ba16681c..cdeda00f 100644 --- a/common/memory.c +++ b/common/memory.c @@ -22,7 +22,7 @@ #ifndef lint static char copyright[] = -"$Id: memory.c,v 1.52.2.14 2000/07/01 05:39:47 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n"; +"$Id: memory.c,v 1.52.2.15 2000/07/01 05:54:22 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ #include "dhcpd.h" @@ -535,9 +535,9 @@ int supersede_lease (comp, lease, commit) enter_hwaddr = 1; /* If the lease has been billed to a class, remove the billing. */ - if (comp -> billing_class && - comp -> billing_class != lease -> billing_class) { - unbill_class (comp, comp -> billing_class); + if (comp -> billing_class != lease -> billing_class) { + if (comp -> billing_class) + unbill_class (comp, comp -> billing_class); if (lease -> billing_class) bill_class (comp, lease -> billing_class); } -- cgit v1.2.1