>>>>> On Fri, 23 Jan 2009 19:32:22 +0100
>>>>> manu@... said:
manu> In a private mail, reschauzier points me something I think is a bug.
manu> The greylist entries held in memory have a p_refcnt field, for reference
manu> count. It avoids the entry being free'ed by a thread while the MX sync
manu> thread is working on it.
manu> It seems there is no similar locking mechanism for the autowhite list. I
manu> think a thread can therefore free an autowhite entry while the sync
manu> thread is working on it. This is likely to lead to a crash.
manu> Anyone has an opinion on this? Did I miss something?
The pending entry and the sync entry share its memory. However, the
autowhite entry has its own memory. When the autowhite entry is
added, it allocates new memory for it, and copy the pending entry to
it by autowhite_get(). So, the autowhite list is not affected by the
MX sync thread.
Am I wrong?
Sincerely,
--
Hajimu UMEMOTO @ Internet Mutual Aid Society Yokohama, Japan
ume@... ume@{,jp.}FreeBSD.org
http://www.imasy.org/~ume/Message
Re: [milter-greylist] locking issue for autowhite list?
2009-01-23 by Hajimu UMEMOTO
Attachments
- No local attachments were found for this message.