bugmake - Bugs: bug #9952, incorrect allocation

 
 

bug #9952: incorrect allocation

Submitted by:  Phil Levis <scipio>
Submitted on:  Mon 09 Aug 2004 11:18:17 PM UTC  
 
Severity: 3 - NormalItem Group: Bug
Status: DuplicatePrivacy: Public
Assigned to: NoneOpen/Closed: Closed
Component Version: 3.80Operating System: POSIX-Based
Fixed Release: NoneTriage Status: None

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

Mon 23 Aug 2004 09:09:33 PM UTC, comment #2:

Applying the patch from bug #1517 fixes the problem.

Phil Levis <scipio>
Tue 17 Aug 2004 09:52:27 PM UTC, comment #1:

I believe this bug has already been fixed. You don't give any idea what construct in your makefile is causing this problem, but if it's happening in an eval you should apply the patch found attached to (the closed) bug # 1517.

Please email me directly as well as following up since Savannah has a bug where added notes are not sent out via email.

Paul D. Smith <psmith>
Project Administrator
Mon 09 Aug 2004 11:18:17 PM UTC, original submission:

When I run make using a fairly complex set of makefiles, I get the error:

make: *** virtual memory exhaused ***. Stop.

My system isn't running out of virtual memory.

This is coming from misc.c:xrealloc, which is being asked to rellocate to a negative size by expand.c:variable_buffer_output().

The bug seems to be stemming from a chain of calls started at misc.c:variable_expand(), which calls variable_expand_string() with NULL as the first parameter. This causes a new variable_buffer to be allocated (expand.c:211); however, variable_buffer_output() is assuming that the ptr argument passed to it is a pointer within variable_buffer. However, as a new variable_buffer was allocated, this isn't the case.

Given that variable_expand() can be called recursively, an imperative reallocation that redefines a global variable seems like a bad idea...

This bug is currently causing problems in the TinyOS build process for complex applications.

Phil Levis <scipio>

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

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

 

 

Follow 2 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Mon 23 Aug 2004 09:45:32 PM UTCpsmithStatusNone=>Duplicate
  Open/ClosedOpen=>Closed

Back to the top


Powered by Savane 3.1-cleanup1