From 1b2232f8babb4d31e1edf175b014e68066ba69fd Mon Sep 17 00:00:00 2001 From: Kaifu Hu Date: Wed, 11 Apr 2018 13:14:43 +0800 Subject: [PATCH] hdmitx: remove NULL characters of aud_cap PD#164062: hdmitx: remove NULL characters of aud_cap remove NULL characters of aud_cap. Change-Id: Ie82de9879071d87c204058e7b81498fe72eb3a19 Signed-off-by: Kaifu Hu --- drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c b/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c index b4954b3aedb4..abbbe9ae6076 100644 --- a/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c +++ b/drivers/amlogic/media/vout/hdmitx/hdmi_tx_20/hdmi_tx_main.c @@ -1756,13 +1756,13 @@ static ssize_t show_aud_cap(struct device *dev, pos += snprintf(buf + pos, PAGE_SIZE, "%s/", aud_sampling_frequency[j+1]); } - pos += snprintf(buf + pos - 1, PAGE_SIZE, " kHz, "); + pos += snprintf(buf + pos - 1, PAGE_SIZE, " kHz, ") - 1; for (j = 0; j < 3; j++) { if (pRXCap->RxAudioCap[i].cc3 & (1 << j)) pos += snprintf(buf + pos, PAGE_SIZE, "%s/", aud_sample_size[j+1]); } - pos += snprintf(buf + pos - 1, PAGE_SIZE, " bit\n"); + pos += snprintf(buf + pos - 1, PAGE_SIZE, " bit\n") - 1; } return pos;