IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 1826


Ignore:
Timestamp:
Sep 17, 2004, 9:23:24 AM (22 years ago)
Author:
evanalst
Message:

Added call to memory exhausted callback to psRealloc if realloc unable to
obtain the desired memory.

Location:
trunk/psLib/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/sys/psMemory.c

    r1821 r1826  
    88*  @author Robert Lupton, Princeton University
    99*
    10 *  @version $Revision: 1.39 $ $Name: not supported by cvs2svn $
    11 *  @date $Date: 2004-09-16 23:51:07 $
     10*  @version $Revision: 1.40 $ $Name: not supported by cvs2svn $
     11*  @date $Date: 2004-09-17 19:23:24 $
    1212*
    1313*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    392392
    393393        if (ptr == NULL) {
    394             psAbort(__func__, "Failed to reallocate %ld bytes at %s:%d", size, file, lineno);
     394            ptr = memExhaustedCallback(size);
     395            if(ptr == NULL) {
     396                psAbort(__func__, "Failed to reallocate %ld bytes at %s:%d", size, file, lineno);
     397            }
    395398        }
    396399
  • trunk/psLib/src/sysUtils/psMemory.c

    r1821 r1826  
    88*  @author Robert Lupton, Princeton University
    99*
    10 *  @version $Revision: 1.39 $ $Name: not supported by cvs2svn $
    11 *  @date $Date: 2004-09-16 23:51:07 $
     10*  @version $Revision: 1.40 $ $Name: not supported by cvs2svn $
     11*  @date $Date: 2004-09-17 19:23:24 $
    1212*
    1313*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    392392
    393393        if (ptr == NULL) {
    394             psAbort(__func__, "Failed to reallocate %ld bytes at %s:%d", size, file, lineno);
     394            ptr = memExhaustedCallback(size);
     395            if(ptr == NULL) {
     396                psAbort(__func__, "Failed to reallocate %ld bytes at %s:%d", size, file, lineno);
     397            }
    395398        }
    396399
Note: See TracChangeset for help on using the changeset viewer.