src/modules/module-detect.c | 2 +- src/modules/udev-util.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-)
New commits: commit 3f0ab4522a6bf77667e3d253755ac5217fbe921a Author: Arun Raghavan <[email protected]> Date: Mon Apr 13 08:34:54 2015 +0530 udev: Deal with unavailable bus property Fixes a compiler warning: ../../src/modules/udev-util.c: In function 'pa_udev_get_info': ../../src/modules/udev-util.c:228:443: warning: 'bus' may be used uninitialized in this function [-Wmaybe-uninitialized] if (!pa_streq(bus, "firewire") && (v = udev_device_get_property_value(card, "ID_MODEL_FROM_DATABASE")) && *v) diff --git a/src/modules/udev-util.c b/src/modules/udev-util.c index d32f8d7..026493b 100644 --- a/src/modules/udev-util.c +++ b/src/modules/udev-util.c @@ -168,7 +168,7 @@ int pa_udev_get_info(int card_idx, pa_proplist *p) { struct udev_device *card = NULL; char *t; const char *v; - const char *bus; + const char *bus = NULL; int id; pa_assert(p); @@ -211,7 +211,7 @@ int pa_udev_get_info(int card_idx, pa_proplist *p) { if (!pa_proplist_contains(p, PA_PROP_DEVICE_VENDOR_NAME)) { /* ID_VENDOR_FROM_DATABASE returns the name of IEEE 1394 Phy/Link chipset for FireWire devices */ - if (!pa_streq(bus, "firewire") && (v = udev_device_get_property_value(card, "ID_VENDOR_FROM_DATABASE")) && *v) + if (!pa_safe_streq(bus, "firewire") && (v = udev_device_get_property_value(card, "ID_VENDOR_FROM_DATABASE")) && *v) pa_proplist_sets(p, PA_PROP_DEVICE_VENDOR_NAME, v); else if ((v = udev_device_get_property_value(card, "ID_VENDOR_ENC")) && *v) proplist_sets_unescape(p, PA_PROP_DEVICE_VENDOR_NAME, v); @@ -225,7 +225,7 @@ int pa_udev_get_info(int card_idx, pa_proplist *p) { if (!pa_proplist_contains(p, PA_PROP_DEVICE_PRODUCT_NAME)) { /* ID_MODEL_FROM_DATABASE returns the name of IEEE 1394 Phy/Link chipset for FireWire devices */ - if (!pa_streq(bus, "firewire") && (v = udev_device_get_property_value(card, "ID_MODEL_FROM_DATABASE")) && *v) + if (!pa_safe_streq(bus, "firewire") && (v = udev_device_get_property_value(card, "ID_MODEL_FROM_DATABASE")) && *v) pa_proplist_sets(p, PA_PROP_DEVICE_PRODUCT_NAME, v); else if ((v = udev_device_get_property_value(card, "ID_MODEL_ENC")) && *v) proplist_sets_unescape(p, PA_PROP_DEVICE_PRODUCT_NAME, v); commit 492fa1ff32ed95d13310ff3b3003564a2a16a06d Author: Andrey Zholos <[email protected]> Date: Mon Apr 13 08:30:46 2015 +0530 detect: Fix OSS device detection with long names Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=89921 diff --git a/src/modules/module-detect.c b/src/modules/module-detect.c index 70bdaca..a9a2de0 100644 --- a/src/modules/module-detect.c +++ b/src/modules/module-detect.c @@ -131,7 +131,7 @@ static int detect_oss(pa_core *c, int just_one) { } while (!feof(f)) { - char line[64], args[64]; + char line[256], args[64]; unsigned device; if (!fgets(line, sizeof(line), f)) _______________________________________________ pulseaudio-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/pulseaudio-commits
