ref: 0062928c4f00f253925a9cc6580066ba2ea2eee1
parent: 4ff9f4afdaa2587184846087bb61ae6419836d89
author: evpobr <[email protected]>
date: Sun Oct 25 07:53:00 EDT 2020
Wrap SRC_MODE_XXX values to SRC_MODE enum * Safe default value (0) * Easer to debug
--- a/src/common.h
+++ b/src/common.h
@@ -66,9 +66,12 @@
enum
{ SRC_FALSE = 0,
SRC_TRUE = 1,
+} ;
- SRC_MODE_PROCESS = 555,
- SRC_MODE_CALLBACK = 556
+enum SRC_MODE
+{
+ SRC_MODE_PROCESS = 0,
+ SRC_MODE_CALLBACK = 1
} ;
enum
@@ -108,7 +111,7 @@
int channels ;
/* SRC_MODE_PROCESS or SRC_MODE_CALLBACK */
- int mode ;
+ enum SRC_MODE mode ;
/* Pointer to data to converter specific data. */
void *private_data ;