bugThe nmh Mail Handling System - Bugs: bug #35242, nmh-1.4: send/post failure

 
 

bug #35242: nmh-1.4: send/post failure

Submitted by:  Harvey Eneman <heneman>
Submitted on:  Thu 05 Jan 2012 12:49:15 AM UTC  
 
Category: NoneSeverity: 3 - Normal
Priority: 5 - NormalStatus: Fixed
Assigned to: NoneOpen/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 06 Feb 2012 04:33:11 PM UTC, comment #4:

Okay, I worked this problem with Mark and I realized the difference was that he had multiple entries in the servers line in mts.conf and I did not.

When I added a second entry to my mts.conf I was able to reproduce the problem, and Harvey's original patch is correct. The patch has been applied to nmh and will be in the next release.

Ken Hornstein <kenh>
Project Administrator
Mon 06 Feb 2012 03:36:29 PM UTC, comment #3:

I have tried both the patches

file #24994: client.c.patch added by kenh (888B - application/octet-stream)
file #24742: client.c.patch added by heneman (1kB - application/octet-stream)

Harvey's 24742 patch works for me, but Ken's 24994 patch does not.

I posted a macports bug (#33143), I have replied to kenh at that forum with a
typescript showing the problem in the debugger.

Mark D. Baushke <mdb>
Mon 06 Feb 2012 03:05:50 PM UTC, comment #2:

Ah-ha. I see it now. I borked up the original client_freelist(); I incremented the list variable after the test, but before calling free! So it would free the second item in the list, never the first, and end up calling free() on NULL every time. Could you please try the revised patch I included below?

(file #24994)

Ken Hornstein <kenh>
Project Administrator
Mon 06 Feb 2012 02:52:37 PM UTC, comment #1:

Hi. Thank you for your bug report. It's also a little weird since I use nmh on MacOS X every day and somehow I don't run into this problem.

I agree completely that the client_freelist should be called on arguments versus ap; that's my bad. But I don't think I agree with the change to client_freelist(); my reading of your change is that it only will free the first entry in the list. Are you sure you need that part of the patch?

Ken Hornstein <kenh>
Project Administrator
Thu 05 Jan 2012 12:49:15 AM UTC, original submission:

post(92684) malloc: *** error for object 0x100102a3a: pointer being freed was not allocated

      • set a breakpoint in malloc_error_break to debug

send: message not delivered to anyone

The attempt to clean up the memory leak in client.c was not implemented appropriately.

The patch attached resolves the issue.

Harvey Eneman <heneman>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #24994:  client.c.patch added by kenh (888B - application/octet-stream)
file #24742:  client.c.patch added by heneman (1KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by mdb (Posted a comment)
  • -unavailable- added by kenh (Posted a comment)
  • -unavailable- added by heneman (Submitted the item)
  •  

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 6 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 06 Feb 2012 04:33:11 PM UTCkenhStatusReady For Test=>Fixed
      Open/ClosedOpen=>Closed
    Mon 06 Feb 2012 03:05:50 PM UTCkenhAttached File-=>Added client.c.patch, #24994
      StatusIn Progress=>Ready For Test
    Mon 06 Feb 2012 02:52:37 PM UTCkenhStatusNone=>In Progress
    Thu 05 Jan 2012 12:49:15 AM UTChenemanAttached File-=>Added client.c.patch, #24742

    Back to the top


    Powered by Savane 3.1-cleanup1