summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2010-10-13 08:25:59 +0300
committerMarcel Holtmann <marcel@holtmann.org>2010-10-13 08:25:59 +0300
commit4cacd3a76c6a577aa40828e1902bbc95e9a09b13 (patch)
tree28ed0531ccf330fad0ee4f8e0b30ee8f2da2d37b
parentb7fbef011bf59f9e64800abad215dee831c567a4 (diff)
downloadofono-4cacd3a76c6a577aa40828e1902bbc95e9a09b13.tar.bz2
atmodem: Send DTMF commands without quotes
The AT+VTS command takes a single character and should not use quotes.
-rw-r--r--drivers/atmodem/voicecall.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/atmodem/voicecall.c b/drivers/atmodem/voicecall.c
index 8b438658..b3c658f5 100644
--- a/drivers/atmodem/voicecall.c
+++ b/drivers/atmodem/voicecall.c
@@ -545,16 +545,15 @@ static void at_send_dtmf(struct ofono_voicecall *vc, const char *dtmf,
if (!cbd)
goto error;
- /* strlen("+VTS=\"T\";") = 9 + initial AT + null */
+ /* strlen("+VTS=T;") = 7 + initial AT + null */
buf = g_try_new(char, len * 9 + 3);
-
if (!buf)
goto error;
- s = sprintf(buf, "AT+VTS=\"%c\"", dtmf[0]);
+ s = sprintf(buf, "AT+VTS=%c", dtmf[0]);
for (i = 1; i < len; i++)
- s += sprintf(buf + s, ";+VTS=\"%c\"", dtmf[i]);
+ s += sprintf(buf + s, ";+VTS=%c", dtmf[i]);
s = g_at_chat_send(vd->chat, buf, none_prefix,
vts_cb, cbd, g_free);