Changeset 1959


Ignore:
Timestamp:
08/26/09 15:10:46 (16 years ago)
Author:
Eric.Larour
Message:

fixed leak in results

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/c/objects/Result.cpp

    r1271 r1959  
    6969        }
    7070
    71         field=result_field; //do not copy, as the results are large in memory size.
     71        VecDuplicatePatch(&field,result_field);
    7272        dfield=NULL;
    7373        cfield=NULL;
     
    9090        }
    9191
    92         dfield=result_field; //do not copy, as the results are large in memory size.
     92        dfield=(double*)xmalloc(result_size*sizeof(double));
     93        memcpy(dfield,result_field,result_size*sizeof(double));
    9394        size=result_size;
    9495        field=NULL;
Note: See TracChangeset for help on using the changeset viewer.