diff options
author | David Robillard <d@drobilla.net> | 2012-01-17 02:13:19 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-01-17 02:13:19 +0000 |
commit | 33b20e5c20b0bbac5db9d8022ee5499b8cb95b5c (patch) | |
tree | 8017b89fe372677d21d73782ab0b2a6a4cdb99b6 /utils/lv2info.c | |
parent | 012e8a8785abcbf403d842d67303d7470b33694c (diff) | |
download | lilv-33b20e5c20b0bbac5db9d8022ee5499b8cb95b5c.tar.gz lilv-33b20e5c20b0bbac5db9d8022ee5499b8cb95b5c.tar.bz2 lilv-33b20e5c20b0bbac5db9d8022ee5499b8cb95b5c.zip |
Support compilation as C++ under MSVC++,
git-svn-id: http://svn.drobilla.net/lad/trunk/lilv@3955 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'utils/lv2info.c')
-rw-r--r-- | utils/lv2info.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/utils/lv2info.c b/utils/lv2info.c index 162a12b..d3a2ade 100644 --- a/utils/lv2info.c +++ b/utils/lv2info.c @@ -14,6 +14,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +#include <float.h> #include <math.h> #include <stdio.h> #include <stdlib.h> @@ -23,6 +24,10 @@ #include "lilv-config.h" +#ifdef _MSC_VER +# define isnan _isnan +#endif + LilvNode* applies_to_pred = NULL; LilvNode* control_class = NULL; LilvNode* event_class = NULL; @@ -307,9 +312,9 @@ print_plugin(LilvWorld* world, /* Ports */ const uint32_t num_ports = lilv_plugin_get_num_ports(p); - float* mins = calloc(num_ports, sizeof(float)); - float* maxes = calloc(num_ports, sizeof(float)); - float* defaults = calloc(num_ports, sizeof(float)); + float* mins = (float*)calloc(num_ports, sizeof(float)); + float* maxes = (float*)calloc(num_ports, sizeof(float)); + float* defaults = (float*)calloc(num_ports, sizeof(float)); lilv_plugin_get_port_ranges_float(p, mins, maxes, defaults); for (uint32_t i = 0; i < num_ports; ++i) |