modules: Use pa_streq instead of strcmp.

This commit is contained in:
Arti Trivedi Bora 2012-06-06 01:28:13 +05:30 committed by Tanu Kaskinen
parent e0c16af551
commit e5954aca8e
19 changed files with 45 additions and 45 deletions

View file

@ -166,7 +166,7 @@ static void resolver_cb(
pa_assert_se(avahi_string_list_get_pair(l, &key, &value, NULL) == 0);
pa_log_debug("Found key: '%s' with value: '%s'", key, value);
if (strcmp(key, "device") == 0) {
if (pa_streq(key, "device")) {
pa_xfree(device);
device = value;
value = NULL;

View file

@ -303,11 +303,11 @@ static void rtsp_cb(pa_rtsp_client *rtsp, pa_rtsp_state state, pa_headerlist* he
while ((token = pa_split(aj, delimiters, &token_state))) {
if ((pc = strstr(token, "="))) {
*pc = 0;
if (!strcmp(token, "type") && !strcmp(pc+1, "digital")) {
if (pa_streq(token, "type") && pa_streq(pc+1, "digital")) {
c->jack_type = JACK_TYPE_DIGITAL;
}
} else {
if (!strcmp(token,"connected"))
if (pa_streq(token, "connected"))
c->jack_status = JACK_STATUS_CONNECTED;
}
pa_xfree(token);