[svn-commits] oej: branch oej/minivoicemail r58459 - /team/oej/minivoicemail/apps/app_minivm.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Thu Mar 8 11:55:29 MST 2007


Author: oej
Date: Thu Mar  8 12:55:28 2007
New Revision: 58459

URL: http://svn.digium.com/view/asterisk?view=rev&rev=58459
Log:
Dude...

Modified:
    team/oej/minivoicemail/apps/app_minivm.c

Modified: team/oej/minivoicemail/apps/app_minivm.c
URL: http://svn.digium.com/view/asterisk/team/oej/minivoicemail/apps/app_minivm.c?view=diff&rev=58459&r1=58458&r2=58459
==============================================================================
--- team/oej/minivoicemail/apps/app_minivm.c (original)
+++ team/oej/minivoicemail/apps/app_minivm.c Thu Mar  8 12:55:28 2007
@@ -449,6 +449,7 @@
 static char *message_template_parse_emailbody(char *body);
 static int create_vmaccount(char *name, struct ast_variable *var, int realtime);
 static struct minivm_account *find_user_realtime(const char *domain, const char *username);
+static int handle_minivm_reload(int fd, int argc, char *argv[]);
 
 /*! \brief Create message template */
 static struct minivm_template *message_template_create(char *name)
@@ -2346,7 +2347,7 @@
 	char *emailbody = strdup(configuration);
 
 	/* substitute strings \t and \n into the apropriate characters */
-	tmpread = tmpwrite = configuration;
+	tmpread = tmpwrite = emailbody;
 	while ((tmpwrite = strchr(tmpread,'\\'))) {
 	       int len = strlen("\n");
 	       switch (tmpwrite[1]) {
@@ -2663,16 +2664,6 @@
 	return res;
 }
 
-/* Forward declaration */
-int reload(void);
-
-/*! \brief Reload cofiguration */
-static int handle_minivm_reload(int fd, int argc, char *argv[])
-{
-	reload();
-	ast_cli(fd, "\n-- Mini voicemail re-configured \n");
-	return RESULT_SUCCESS;
-}
 
 static char *complete_minivm_show_users(const char *line, const char *word, int pos, int state)
 {
@@ -2909,6 +2900,14 @@
 	return(load_config());
 }
 
+/*! \brief Reload cofiguration */
+static int handle_minivm_reload(int fd, int argc, char *argv[])
+{
+	reload();
+	ast_cli(fd, "\n-- Mini voicemail re-configured \n");
+	return RESULT_SUCCESS;
+}
+
 /*! \brief Unload mini voicemail module */
 int unload_module(void)
 {
@@ -2918,6 +2917,7 @@
 	res |= ast_unregister_application(app_minivm_greet);
 	res |= ast_unregister_application(app_minivm_notify);
 	res |= ast_unregister_application(app_minivm_delete);
+	res |= ast_unregister_application(app_minivm_accmess);
 	ast_cli_unregister_multiple(cli_minivm, sizeof(cli_minivm)/sizeof(cli_minivm[0]));
 	ast_custom_function_unregister(&minivm_account_function);
 



More information about the svn-commits mailing list