Index: uspace/srv/audio/hound/audio_device.c
===================================================================
--- uspace/srv/audio/hound/audio_device.c	(revision c81132d46eede2bacb1fa051d014dfb0a88d0ace)
+++ uspace/srv/audio/hound/audio_device.c	(revision 3b47db687606b55f2694aaa5c4c6db563b5b61eb)
@@ -51,10 +51,10 @@
 #define BUFFER_PARTS   16
 
-static int device_sink_connection_callback(audio_sink_t *sink, bool new);
-static int device_source_connection_callback(audio_source_t *source, bool new);
+static errno_t device_sink_connection_callback(audio_sink_t *sink, bool new);
+static errno_t device_source_connection_callback(audio_source_t *source, bool new);
 static void device_event_callback(ipc_callid_t iid, ipc_call_t *icall, void *arg);
-static int device_check_format(audio_sink_t* sink);
-static int get_buffer(audio_device_t *dev);
-static int release_buffer(audio_device_t *dev);
+static errno_t device_check_format(audio_sink_t* sink);
+static errno_t get_buffer(audio_device_t *dev);
+static errno_t release_buffer(audio_device_t *dev);
 static void advance_buffer(audio_device_t *dev, size_t size);
 static inline bool is_running(audio_device_t *dev)
@@ -72,5 +72,5 @@
  * @return Error code.
  */
-int audio_device_init(audio_device_t *dev, service_id_t id, const char *name)
+errno_t audio_device_init(audio_device_t *dev, service_id_t id, const char *name)
 {
 	assert(dev);
@@ -122,5 +122,5 @@
 	assert(dev);
 	sysarg_t val;
-	int rc = audio_pcm_query_cap(dev->sess, AUDIO_CAP_CAPTURE, &val);
+	errno_t rc = audio_pcm_query_cap(dev->sess, AUDIO_CAP_CAPTURE, &val);
 	if (rc == EOK && val)
 		return &dev->source;
@@ -138,5 +138,5 @@
 	assert(dev);
 	sysarg_t val;
-	int rc = audio_pcm_query_cap(dev->sess, AUDIO_CAP_PLAYBACK, &val);
+	errno_t rc = audio_pcm_query_cap(dev->sess, AUDIO_CAP_PLAYBACK, &val);
 	if (rc == EOK && val)
 		return &dev->sink;
@@ -153,5 +153,5 @@
  * connections.
  */
-static int device_sink_connection_callback(audio_sink_t* sink, bool new)
+static errno_t device_sink_connection_callback(audio_sink_t* sink, bool new)
 {
 	assert(sink);
@@ -160,5 +160,5 @@
 		log_verbose("First connection on device sink '%s'", sink->name);
 
-		int ret = get_buffer(dev);
+		errno_t ret = get_buffer(dev);
 		if (ret != EOK) {
 			log_error("Failed to get device buffer: %s",
@@ -196,5 +196,5 @@
 		log_verbose("Removed last connection on device sink '%s'",
 		    sink->name);
-		int ret = audio_pcm_stop_playback(dev->sess);
+		errno_t ret = audio_pcm_stop_playback(dev->sess);
 		if (ret != EOK) {
 			log_error("Failed to stop playback: %s",
@@ -215,10 +215,10 @@
  * connections.
  */
-static int device_source_connection_callback(audio_source_t *source, bool new)
+static errno_t device_source_connection_callback(audio_source_t *source, bool new)
 {
 	assert(source);
 	audio_device_t *dev = source->private_data;
 	if (new && list_count(&source->connections) == 1) {
-		int ret = get_buffer(dev);
+		errno_t ret = get_buffer(dev);
 		if (ret != EOK) {
 			log_error("Failed to get device buffer: %s",
@@ -244,5 +244,5 @@
 	if (list_count(&source->connections) == 0) { /* Disconnected */
 		assert(!new);
-		int ret = audio_pcm_stop_capture_immediate(dev->sess);
+		errno_t ret = audio_pcm_stop_capture_immediate(dev->sess);
 		if (ret != EOK) {
 			log_error("Failed to start recording: %s",
@@ -289,5 +289,5 @@
 			log_verbose("Capture terminated");
 			dev->source.format = AUDIO_FORMAT_ANY;
-			const int ret = release_buffer(dev);
+			const errno_t ret = release_buffer(dev);
 			if (ret != EOK) {
 				log_error("Failed to release buffer: %s",
@@ -300,5 +300,5 @@
 			log_verbose("Playback Terminated");
 			dev->sink.format = AUDIO_FORMAT_ANY;
-			const int ret = release_buffer(dev);
+			const errno_t ret = release_buffer(dev);
 			if (ret != EOK) {
 				log_error("Failed to release buffer: %s",
@@ -309,5 +309,5 @@
 		}
 		case PCM_EVENT_FRAMES_CAPTURED: {
-			const int ret = audio_source_push_data(&dev->source,
+			const errno_t ret = audio_source_push_data(&dev->source,
 			    dev->buffer.position, dev->buffer.fragment_size);
 			advance_buffer(dev, dev->buffer.fragment_size);
@@ -329,5 +329,5 @@
  * @return Error code.
  */
-static int device_check_format(audio_sink_t* sink)
+static errno_t device_check_format(audio_sink_t* sink)
 {
 	assert(sink);
@@ -347,5 +347,5 @@
  * @return Error code.
  */
-static int get_buffer(audio_device_t *dev)
+static errno_t get_buffer(audio_device_t *dev)
 {
 	assert(dev);
@@ -362,5 +362,5 @@
 	size_t preferred_size = 0;
 
-	const int ret = audio_pcm_get_buffer(dev->sess, &dev->buffer.base,
+	const errno_t ret = audio_pcm_get_buffer(dev->sess, &dev->buffer.base,
 	    &preferred_size);
 	if (ret == EOK) {
@@ -378,10 +378,10 @@
  * @return Error code.
  */
-static int release_buffer(audio_device_t *dev)
+static errno_t release_buffer(audio_device_t *dev)
 {
 	assert(dev);
 	assert(dev->buffer.base);
 
-	const int ret = audio_pcm_release_buffer(dev->sess);
+	const errno_t ret = audio_pcm_release_buffer(dev->sess);
 	if (ret == EOK) {
 		as_area_destroy(dev->buffer.base);
