Changeset 0e3bb5 in git for kernel/GBEngine


Ignore:
Timestamp:
Nov 10, 2021, 10:40:57 PM (3 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', 'd08f5f0bb3329b8ca19f23b74cb1473686415c3a')
Children:
44e1d6d6bd726ede0164014a5a50ac008bc42aad
Parents:
b992463aa28e647f5164c04e2f050ffc6772a29a
Message:
more omrealloc ->omreallocSize
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/GBEngine/tgb.cc

    rb99246 r0e3bb5  
    14131413  }
    14141414
    1415 #define ENLARGE(pointer, type) pointer=(type*) omrealloc(pointer, c->array_lengths*sizeof(type))
     1415#define ENLARGE(pointer, type) pointer=(type*) omreallocSize(pointer, old*sizeof(type),c->array_lengths*sizeof(type))
    14161416
    14171417#define ENLARGE_ALIGN(pointer, type) {if(pointer)\
    1418          pointer=(type*)omReallocAligned(pointer, c->array_lengths*sizeof(type));\
     1418         pointer=(type*)omReallocSize(pointer, old*sizeof(type),c->array_lengths*sizeof(type));\
    14191419         else pointer=(type*)omAllocAligned(c->array_lengths*sizeof(type));}
    14201420//  BOOLEAN corr=lenS_correct(c->strat);
     
    14281428    (sorted_pair_node **) omalloc (sizeof (sorted_pair_node *) * i);
    14291429  int spc = 0;
     1430  int old=c->array_lengths;
    14301431  if(c->n > c->array_lengths)
    14311432  {
     
    48254826      int i;
    48264827      for(i = 0; c->expandS[i]; i++) ;
    4827       c->expandS = (poly *) omrealloc (c->expandS, (i + 2) * sizeof (poly));
     4828      c->expandS = (poly *) omreallocSize (c->expandS, (i+1)*sizeof(poly),
     4829                                                       (i+2)*sizeof(poly));
    48284830      c->expandS[i] = erg.expand;
    48294831      c->expandS[i + 1] = NULL;
Note: See TracChangeset for help on using the changeset viewer.