[ATM]: fix bug in atm address list handling

From: Martin Whitaker <atm@martin-whitaker.co.uk>
Signed-off-by: Chas Williams <chas@cmf.nrl.navy.mil>
This commit is contained in:
Martin Whitaker 2005-09-28 16:35:22 -07:00 committed by David S. Miller
parent 9301e320e9
commit 735631a919
1 changed files with 4 additions and 2 deletions

View File

@ -50,8 +50,10 @@ void atm_reset_addr(struct atm_dev *dev)
struct atm_dev_addr *this, *p;
spin_lock_irqsave(&dev->lock, flags);
list_for_each_entry_safe(this, p, &dev->local, entry)
kfree(this);
list_for_each_entry_safe(this, p, &dev->local, entry) {
list_del(&this->entry);
kfree(this);
}
spin_unlock_irqrestore(&dev->lock, flags);
notify_sigd(dev);
}