commit - d0d4de498000ff80d11aaa35509f082a80bb317e
commit + 0dc3c134697444e1470c87c6f22211ba220ec4ec
blob - 82e0cf0155a0cf32c939c9078731e9d09623c18f
blob + 380b9078b210deb9a6853cf2c966357efec75481
--- src/ngircd/numeric.c
+++ src/ngircd/numeric.c
CHANNEL *c;
struct list_head *head;
struct list_elem *elem;
+ time_t t;
assert(Client != NULL);
head = Class_GetList(CLASS_GLINE);
elem = Lists_GetFirst(head);
while (elem) {
+ t = Lists_GetValidity(elem) - time(NULL);
if (!IRC_WriteStrClient(Client, "GLINE %s %ld :%s",
Lists_GetMask(elem),
- (long)(Lists_GetValidity(elem) - time(NULL)),
+ t > 0 ? (long)t : 0,
Lists_GetReason(elem)))
return DISCONNECTED;
elem = Lists_GetNext(elem);