[pulseaudio-discuss] [PATCH 4/8] daemon: change pa_bool_t to bool

Deng Zhengrong dzrongg at gmail.com
Sun Jul 1 08:46:06 PDT 2012


---
 src/daemon/cpulimit.c      |    2 +-
 src/daemon/daemon-conf.c   |    4 ++--
 src/daemon/daemon-conf.h   |    4 ++--
 src/daemon/main.c          |   10 +++++-----
 src/daemon/server-lookup.c |    2 +-
 5 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/src/daemon/cpulimit.c b/src/daemon/cpulimit.c
index 3a97297..5b27f09 100644
--- a/src/daemon/cpulimit.c
+++ b/src/daemon/cpulimit.c
@@ -80,7 +80,7 @@ static pa_io_event *io_event = NULL;
 static struct sigaction sigaction_prev;
 
 /* Nonzero after pa_cpu_limit_init() */
-static pa_bool_t installed = FALSE;
+static bool installed = FALSE;
 
 /* The current state of operation */
 static enum {
diff --git a/src/daemon/daemon-conf.c b/src/daemon/daemon-conf.c
index dd2e7b6..a94750d 100644
--- a/src/daemon/daemon-conf.c
+++ b/src/daemon/daemon-conf.c
@@ -396,8 +396,8 @@ static int parse_alternate_sample_rate(const char *filename, unsigned line, cons
 
 struct channel_conf_info {
     pa_daemon_conf *conf;
-    pa_bool_t default_sample_spec_set;
-    pa_bool_t default_channel_map_set;
+    bool default_sample_spec_set;
+    bool default_channel_map_set;
 };
 
 static int parse_sample_channels(const char *filename, unsigned line, const char *section, const char *lvalue, const char *rvalue, void *data, void *userdata) {
diff --git a/src/daemon/daemon-conf.h b/src/daemon/daemon-conf.h
index faf2540..a3f7140 100644
--- a/src/daemon/daemon-conf.h
+++ b/src/daemon/daemon-conf.h
@@ -52,14 +52,14 @@ typedef enum pa_daemon_conf_cmd {
 #ifdef HAVE_SYS_RESOURCE_H
 typedef struct pa_rlimit {
     rlim_t value;
-    pa_bool_t is_set;
+    bool is_set;
 } pa_rlimit;
 #endif
 
 /* A structure containing configuration data for the PulseAudio server . */
 typedef struct pa_daemon_conf {
     pa_daemon_conf_cmd_t cmd;
-    pa_bool_t daemonize,
+    bool daemonize,
         fail,
         high_priority,
         realtime_scheduling,
diff --git a/src/daemon/main.c b/src/daemon/main.c
index a67bf06..761273b 100644
--- a/src/daemon/main.c
+++ b/src/daemon/main.c
@@ -400,8 +400,8 @@ int main(int argc, char *argv[]) {
     char *s;
     char *configured_address;
     int r = 0, retval = 1, d = 0;
-    pa_bool_t valid_pid_file = FALSE;
-    pa_bool_t ltdl_init = FALSE;
+    bool valid_pid_file = FALSE;
+    bool ltdl_init = FALSE;
     int passed_fd = -1;
     const char *e;
 #ifdef HAVE_FORK
@@ -413,12 +413,12 @@ int main(int argc, char *argv[]) {
     struct timeval win32_tv;
 #endif
     int autospawn_fd = -1;
-    pa_bool_t autospawn_locked = FALSE;
+    bool autospawn_locked = FALSE;
 #ifdef HAVE_DBUS
     pa_dbusobj_server_lookup *server_lookup = NULL; /* /org/pulseaudio/server_lookup */
     pa_dbus_connection *lookup_service_bus = NULL; /* Always the user bus. */
     pa_dbus_connection *server_bus = NULL; /* The bus where we reserve org.pulseaudio.Server, either the user or the system bus. */
-    pa_bool_t start_server;
+    bool start_server;
 #endif
 
     pa_log_set_ident("pulseaudio");
@@ -677,7 +677,7 @@ int main(int argc, char *argv[]) {
          * recover (i.e. autospawn) from a crash.
          */
         char *ufn;
-        pa_bool_t start_anyway = FALSE;
+        bool start_anyway = FALSE;
 
         if ((ufn = pa_runtime_path(PA_NATIVE_DEFAULT_UNIX_SOCKET))) {
             char *id;
diff --git a/src/daemon/server-lookup.c b/src/daemon/server-lookup.c
index 9bdc699..8d27486 100644
--- a/src/daemon/server-lookup.c
+++ b/src/daemon/server-lookup.c
@@ -42,7 +42,7 @@
 struct pa_dbusobj_server_lookup {
     pa_core *core;
     pa_dbus_connection *conn;
-    pa_bool_t path_registered;
+    bool path_registered;
 };
 
 static const char introspection[] =
-- 
1.7.7.6



More information about the pulseaudio-discuss mailing list