Changeset 505 for trunk/matml
- Timestamp:
- 11/30/2009 04:18:53 PM (2 years ago)
- Files:
-
- 1 modified
-
trunk/matml/src/ternary/spinodal.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/matml/src/ternary/spinodal.c
r483 r505 452 452 { 453 453 spinreturn->compos = 2; 454 if (!(thesegs = (int *) realloc 455 (thesegs, 2*numsegs*sizeof (int)))) 456 { free (thenewpoints); free (thesegs); return 1; } 454 if (numsegs) 455 { 456 if (!(thesegs = (int *) realloc 457 (thesegs, 2*numsegs*sizeof (int)))) 458 { free (thenewpoints); free (thesegs); return 1; } 459 } 460 else 461 { 462 free (thesegs); 463 thesegs = NULL; 464 } 457 465 spinreturn->edges = thesegs; 458 466 #ifdef DEBUG