aboutsummaryrefslogtreecommitdiffstats
path: root/src/output_internal.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-29 20:40:27 +0100
committerMax Kellermann <max@duempel.org>2008-10-29 20:40:27 +0100
commit58c5bee9f0bcb46da7d113b66a4e1e2d7add9837 (patch)
tree4517d2156aa3643247e7f2fc886af86d3dfd8791 /src/output_internal.h
parent03390d8be1cb8983778faf6eedb9bcfd26a6dbce (diff)
downloadmpd-58c5bee9f0bcb46da7d113b66a4e1e2d7add9837.tar.gz
mpd-58c5bee9f0bcb46da7d113b66a4e1e2d7add9837.tar.xz
mpd-58c5bee9f0bcb46da7d113b66a4e1e2d7add9837.zip
output: use bool for return values and flags
Don't return 0/-1 on success/error, but true/false. Instead of int, use bool for storing flags.
Diffstat (limited to '')
-rw-r--r--src/output_internal.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/output_internal.h b/src/output_internal.h
index fc146546a..d3f650086 100644
--- a/src/output_internal.h
+++ b/src/output_internal.h
@@ -43,7 +43,7 @@ struct audio_output {
/**
* Is the device (already) open and functional?
*/
- int open;
+ bool open;
/**
* The audio_format in which audio data is received from the
@@ -98,9 +98,9 @@ struct audio_output {
} args;
/**
- * Result value of the command. Generally, "0" means success.
+ * Result value of the command. true means success.
*/
- int result;
+ bool result;
};
/**
@@ -109,19 +109,19 @@ struct audio_output {
*/
extern struct notify audio_output_client_notify;
-static inline int
+static inline bool
audio_output_is_open(const struct audio_output *ao)
{
return ao->open;
}
-static inline int
+static inline bool
audio_output_command_is_finished(const struct audio_output *ao)
{
return ao->command == AO_COMMAND_NONE;
}
-static inline int
+static inline bool
audio_output_get_result(const struct audio_output *ao)
{
return ao->result;