shithub: sox

Download patch

ref: 48a6aa0295d1285696bb19589c318c80e86f972f
parent: 0162b6ff95c1996e41bdff9cd8604900d3dc6c9f
author: robs <robs>
date: Mon Feb 2 04:42:34 EST 2009

a macro is better than a function here, but other code needes to be updated 1st

--- a/src/sox_i.h
+++ b/src/sox_i.h
@@ -180,10 +180,15 @@
 int lsx_readf(sox_format_t * ft, float * f);
 int lsx_readw(sox_format_t * ft, uint16_t * uw);
 
+#if 1 /* FIXME: use defines */
 UNUSED static int lsx_readsb(sox_format_t * ft, int8_t * sb)
-  {return lsx_readb(ft, (uint8_t *)sb);}
+{return lsx_readb(ft, (uint8_t *)sb);}
 UNUSED static int lsx_readsw(sox_format_t * ft, int16_t * sw)
-  {return lsx_readw(ft, (uint16_t *)sw);}
+{return lsx_readw(ft, (uint16_t *)sw);}
+#else
+#define lsx_readsb(ft, sb) lsx_readb(ft, (uint8_t *)sb)
+#define lsx_readsw(ft, sw) lsx_readb(ft, (uint16_t *)sw)
+#endif
 
 int lsx_write3(sox_format_t * ft, unsigned u3);
 int lsx_writeb(sox_format_t * ft, unsigned ub);