HylaFAX The world's most advanced open source fax server

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [hylafax-users] FaxQueuer crashing/exiting after two jobs submitted at once



Aidan Van Dyk wrote:

* Lee Howard <faxguy@xxxxxxxxxxxxxxxx> [070222 14:35]:


The solution in my case was to change a few faxq calls of

job.remove();

to become

if (job.isOnList()) job.remove();

Blindly removing calls to job.remove() is a sure-fire way to get memory
leaks in faxq.  They are not huge (probably on the order of 64 bytes /
job), but could add up after many 1000s of jobs.


I wouldn't characterize my approach as "blind". When we get to a job.remove() and the job is not on a list we have two options: skip the job.remove and deal with the consequences or die with the assert error.


The real problem came earlier - we shouldn't even be considering a job.remove if the job isn't on a list in the first place. However, the asynchronicity makes faxq rather difficult to debug on rare timing issues like this.

I was, in the most grevious instances, seeing those assert errors once per day. Even if it does leak 64 bytes per instance that would have taken me 45 years of uptime to even leak a megabyte. In my opinion that's favorable to dying.

Lee.

____________________ HylaFAX(tm) Users Mailing List _______________________
 To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null
 *To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*




Project hosted by iFAX Solutions