aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/alsa/alsa-api-source.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/alsa/alsa-api-source.c')
-rw-r--r--plugins/alsa/alsa-api-source.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/plugins/alsa/alsa-api-source.c b/plugins/alsa/alsa-api-source.c
index d227eab..02f009b 100644
--- a/plugins/alsa/alsa-api-source.c
+++ b/plugins/alsa/alsa-api-source.c
@@ -36,13 +36,13 @@ PUBLIC AlsaSndCtlT *ApiSourceFindSubdev(SoftMixerT *mixer, const char *target) {
static void sourceDestroy(SoftMixerT* mixer, void * arg) {
AlsaSndPcmT * source = (AlsaSndPcmT*) arg;
- AFB_ApiDebug(mixer->api, "%s... %s", __func__, source->uid);
+ AFB_API_DEBUG(mixer->api, "%s... %s", __func__, source->uid);
cds_list_del(&source->list);
mixer->nbSources--;
ApiPcmDelete(mixer, source);
- AFB_ApiDebug(mixer->api, "%s... DONE", __func__);
+ AFB_API_DEBUG(mixer->api, "%s... DONE", __func__);
}
static AlsaSndPcmT * sourceCreate(SoftMixerT* mixer, const char * uid, json_object * argsJ) {
@@ -60,10 +60,10 @@ fail:
return newSource;
}
-PUBLIC int ApiSourceAttach(SoftMixerT *mixer, AFB_ReqT request, const char * uid, json_object * argsJ) {
+PUBLIC int ApiSourceAttach(SoftMixerT *mixer, afb_req_t request, const char * uid, json_object * argsJ) {
if (mixer->nbSources >= mixer->max.sources) {
- AFB_ReqFailF(request, "too-small", "mixer=%s max source=%d", mixer->uid, mixer->max.sources);
+ afb_req_fail_f(request, "too-small", "mixer=%s max source=%d", mixer->uid, mixer->max.sources);
goto fail;
}
@@ -75,7 +75,7 @@ PUBLIC int ApiSourceAttach(SoftMixerT *mixer, AFB_ReqT request, const char * uid
case json_type_object:
newSource = sourceCreate(mixer, uid, argsJ);
if (!newSource) {
- AFB_ReqFailF(request, "bad-pcm", "mixer=%s invalid source= %s", mixer->uid, json_object_get_string(argsJ));
+ afb_req_fail_f(request, "bad-pcm", "mixer=%s invalid source= %s", mixer->uid, json_object_get_string(argsJ));
goto fail;
}
@@ -84,7 +84,7 @@ PUBLIC int ApiSourceAttach(SoftMixerT *mixer, AFB_ReqT request, const char * uid
case json_type_array:
count = json_object_array_length(argsJ);
if (count > (mixer->max.sources - mixer->nbSources)) {
- AFB_ReqFailF(request, "too-small", "mixer=%s max source=%d", mixer->uid, mixer->max.sources);
+ afb_req_fail_f(request, "too-small", "mixer=%s max source=%d", mixer->uid, mixer->max.sources);
goto fail;
}
@@ -92,14 +92,14 @@ PUBLIC int ApiSourceAttach(SoftMixerT *mixer, AFB_ReqT request, const char * uid
json_object *sourceJ = json_object_array_get_idx(argsJ, idx);
newSource = sourceCreate(mixer, uid, sourceJ);
if (!newSource) {
- AFB_ReqFailF(request, "bad-pcm", "mixer=%s invalid source= %s", mixer->uid, json_object_get_string(sourceJ));
+ afb_req_fail_f(request, "bad-pcm", "mixer=%s invalid source= %s", mixer->uid, json_object_get_string(sourceJ));
goto fail;
}
}
break;
default:
- AFB_ReqFailF(request, "invalid-syntax", "mixer=%s sources invalid argsJ= %s", mixer->uid, json_object_get_string(argsJ));
+ afb_req_fail_f(request, "invalid-syntax", "mixer=%s sources invalid argsJ= %s", mixer->uid, json_object_get_string(argsJ));
goto fail;
}