maxl0rd/standingwave3 — pull request #18 by jbaudanza (2011-11-04 22:53:55+00:00)
Title: Checking for NULL after calls to malloc, and throwing an Error

Hey Max,

This is the change I e-mailed you about. LMK what you think.

I didn't touch `reallocateSampleMemory` in awave.com because I'm not sure I understand how it works.

```c
float *buffer;

AS3_ArrayValue(args, "IntType, IntType, IntType", &oldframes, &newframes, &channels);

oldsize = oldframes * channels * sizeof(float);
newsize = newframes * channels * sizeof(float);

// realloc is slow :(
buffer = (float *) realloc(buffer, newsize);
```

It looks like `buffer` is being passed into realloc without being initialized to any value