summaryrefslogtreecommitdiffstats
path: root/audio/telephony-maemo.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2008-12-04 12:39:54 +0200
committerJohan Hedberg <johan.hedberg@nokia.com>2008-12-08 16:10:58 +0200
commite1365d555958d61866304f53588bc24b317d5e69 (patch)
treeb08f0671f1693aff0788aa12d21aa9c92647ea42 /audio/telephony-maemo.c
parent44ff2eec436a6d06cd3780972e89fd1bf0d42002 (diff)
Assign voice mailbox to memory location 1
Diffstat (limited to 'audio/telephony-maemo.c')
-rw-r--r--audio/telephony-maemo.c21
1 files changed, 18 insertions, 3 deletions
diff --git a/audio/telephony-maemo.c b/audio/telephony-maemo.c
index 33793f19..78a6c641 100644
--- a/audio/telephony-maemo.c
+++ b/audio/telephony-maemo.c
@@ -494,9 +494,17 @@ void telephony_answer_call_req(void *telephony_device)
telephony_answer_call_rsp(telephony_device, CME_ERROR_NONE);
}
+const char *memory_dial_lookup(int location)
+{
+ if (location == 1)
+ return vmbx;
+ else
+ return NULL;
+}
+
void telephony_dial_number_req(void *telephony_device, const char *number)
{
- uint32_t flags;
+ uint32_t flags = CALL_FLAG_NONE;
DBusMessage *msg;
debug("telephony-maemo: dial request to %s", number);
@@ -507,8 +515,15 @@ void telephony_dial_number_req(void *telephony_device, const char *number)
} else if (strncmp(number, "#31#", 4) == 0) {
number += 4;
flags = CALL_FLAG_PRESENTATION_RESTRICTED;
- } else
- flags = CALL_FLAG_NONE;
+ } else if (number[0] == '>') {
+ number = memory_dial_lookup(strtol(&number[1], NULL, 0));
+ if (!number) {
+ error("No number at memory location %s", &number[1]);
+ telephony_dial_number_rsp(telephony_device,
+ CME_ERROR_INVALID_INDEX);
+ return;
+ }
+ }
msg = dbus_message_new_method_call(CSD_CALL_BUS_NAME, CSD_CALL_PATH,
CSD_CALL_INTERFACE, "CreateWith");