Changeset 12079

Show
Ignore:
Timestamp:
09/05/07 16:06:43 (1 year ago)
Author:
rouault
Message:

Fix for bug #1795 (jpeg driver and temporary file)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/gdal/frmts/jpeg/jpgdataset.cpp

    r12061 r12079  
    13491349    jpeg_create_decompress( &(poDS->sDInfo) ); 
    13501350 
     1351    /* This is to address bug related in ticket #1795 */ 
     1352    if (CPLGetConfigOption("JPEGMEM", NULL) == NULL) 
     1353    { 
     1354        /* If the user doesn't provide a value for JPEGMEM, we want to be sure */ 
     1355        /* that at least 500 MB will be used before creating the temporary file */ 
     1356        poDS->sDInfo.mem->max_memory_to_use = 
     1357                MAX(poDS->sDInfo.mem->max_memory_to_use, 500 * 1024 * 1024); 
     1358    } 
     1359 
    13511360/* -------------------------------------------------------------------- */ 
    13521361/*      Preload default NITF JPEG quantization tables.                  */