shithub: dumb

Download patch

ref: 5945794aff46562478ff764a841e085448046125
parent: bf5dd80894f947d3eca15960ca1b329e9ccde677
author: Chris Moeller <[email protected]>
date: Fri Oct 4 09:14:52 EDT 2013

Fixed a C11 warning by adding a macro lock around blip_t declaration

--- a/dumb/include/dumb.h
+++ b/dumb/include/dumb.h
@@ -679,7 +679,10 @@
 
 typedef void (*DUMB_RESAMPLE_PICKUP)(DUMB_RESAMPLER *resampler, void *data);
 
+#ifndef BLIP_T_DEFINED
+#define BLIP_T_DEFINED
 typedef struct blip_t blip_t;
+#endif
 
 struct DUMB_RESAMPLER
 {
--- a/dumb/include/internal/blip_buf.h
+++ b/dumb/include/internal/blip_buf.h
@@ -11,7 +11,10 @@
 
 /** First parameter of most functions is blip_t*, or const blip_t* if nothing
 is changed. */
+#ifndef BLIP_T_DEFINED
+#define BLIP_T_DEFINED
 typedef struct blip_t blip_t;
+#endif
 
 /** Creates new buffer that can hold at most sample_count samples. Sets rates
 so that there are blip_max_ratio clocks per sample. Returns pointer to new