summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAlexandre Ratchov <ratchov@cvs.openbsd.org>2009-05-15 13:06:41 +0000
committerAlexandre Ratchov <ratchov@cvs.openbsd.org>2009-05-15 13:06:41 +0000
commit6ca72687c46f4e2a5ad5cce7c6194a0a9210756d (patch)
tree9f5aca5cb93fd63d1325ff912046ec28557e138d /lib
parentda905942dc60b809fc67abd8809df614abeb2bd0 (diff)
in headers, macro definitions come first, prototypes come next
Diffstat (limited to 'lib')
-rw-r--r--lib/libsndio/sndio_priv.h32
1 files changed, 17 insertions, 15 deletions
diff --git a/lib/libsndio/sndio_priv.h b/lib/libsndio/sndio_priv.h
index 670bb9bb818..f35a31abdfd 100644
--- a/lib/libsndio/sndio_priv.h
+++ b/lib/libsndio/sndio_priv.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: sndio_priv.h,v 1.6 2009/05/15 13:04:52 ratchov Exp $ */
+/* $OpenBSD: sndio_priv.h,v 1.7 2009/05/15 13:06:40 ratchov Exp $ */
/*
* Copyright (c) 2008 Alexandre Ratchov <alex@caoua.org>
*
@@ -20,6 +20,22 @@
#include <sys/param.h>
#include "sndio.h"
+#ifdef DEBUG
+#define DPRINTF(...) \
+ do { \
+ if (sio_debug > 0) \
+ fprintf(stderr, __VA_ARGS__); \
+ } while(0)
+#define DPERROR(s) \
+ do { \
+ if (sio_debug > 0) \
+ perror(s); \
+ } while(0)
+#else
+#define DPRINTF(...) do {} while(0)
+#define DPERROR(s) do {} while(0)
+#endif
+
/*
* private ``handle'' structure
*/
@@ -70,20 +86,6 @@ void sio_onvol_cb(struct sio_hdl *, unsigned);
#ifdef DEBUG
extern int sio_debug;
-
-#define DPRINTF(...) \
- do { \
- if (sio_debug > 0) \
- fprintf(stderr, __VA_ARGS__); \
- } while(0)
-#define DPERROR(s) \
- do { \
- if (sio_debug > 0) \
- perror(s); \
- } while(0)
-#else
-#define DPRINTF(...) do {} while(0)
-#define DPERROR(s) do {} while(0)
#endif
#endif /* !defined(SNDIO_PRIV_H) */