Version 0.1.8 from FTP
[asterisk/asterisk.git] / apps / app_voicemail.c
index 939587f..45a6229 100755 (executable)
@@ -329,7 +329,7 @@ static int vm_execmain(struct ast_channel *chan, void *data)
        }
        do {
                /* Prompt for, and read in the username */
-               if (ast_readstring(chan, username, sizeof(username), 2000, 5000, "#")) {
+               if (ast_readstring(chan, username, sizeof(username), 2000, 10000, "#")) {
                        ast_log(LOG_WARNING, "Couldn't read username\n");
                        goto out;
                }                       
@@ -343,7 +343,7 @@ static int vm_execmain(struct ast_channel *chan, void *data)
                        ast_log(LOG_WARNING, "Unable to stream password file\n");
                        goto out;
                }
-               if (ast_readstring(chan, password, sizeof(password), 2000, 5000, "#")) {
+               if (ast_readstring(chan, password, sizeof(password), 2000, 10000, "#")) {
                        ast_log(LOG_WARNING, "Unable to read password\n");
                        goto out;
                }
@@ -418,7 +418,7 @@ static int vm_execmain(struct ast_channel *chan, void *data)
                        ast_verbose( VERBOSE_PREFIX_3 "User '%s' logged in on channel %s with %d messages\n", username, chan->name, maxmsg);
                if (!ast_streamfile(chan, "vm-instructions", chan->language)) {
                        for(;;) {
-                               if (chan->stream || (chan->trans && chan->trans->stream)) {
+                               if (chan->stream) {
                                        d = ast_waitstream(chan, AST_DIGIT_ANY);
                                        ast_stopstream(chan);
                                        if (!d && (state == STATE_MESSAGE_PLAYING)) {
@@ -616,3 +616,8 @@ int usecount(void)
        STANDARD_USECOUNT(res);
        return res;
 }
+
+char *key()
+{
+       return ASTERISK_GPL_KEY;
+}