Browse Source

Better MALLOC macro.

NathanSweet 10 years ago
parent
commit
dee4d7f801
1 changed files with 1 additions and 1 deletions
  1. 1 1
      spine-c/include/spine/extension.h

+ 1 - 1
spine-c/include/spine/extension.h

@@ -32,7 +32,7 @@
 #define SPINE_EXTENSION_H_
 
 /* All allocation uses these. */
-#define MALLOC(TYPE,COUNT) ((TYPE*)_malloc(sizeof(TYPE) * COUNT, __FILE__, __LINE__))
+#define MALLOC(TYPE,COUNT) ((TYPE*)_malloc(sizeof(TYPE) * (COUNT), __FILE__, __LINE__))
 #define CALLOC(TYPE,COUNT) ((TYPE*)_calloc(COUNT, sizeof(TYPE), __FILE__, __LINE__))
 #define NEW(TYPE) CALLOC(TYPE,1)