- fixed an error in the last commit
authorAnca Vamanu <anca@voice-system.ro>
Tue, 23 Oct 2007 14:30:43 +0000 (14:30 +0000)
committerAnca Vamanu <anca@voice-system.ro>
Tue, 23 Oct 2007 14:30:43 +0000 (14:30 +0000)
git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@2980 689a6050-402a-0410-94f2-e92a70836424

modules_k/presence/publish.c
modules_k/presence/subscribe.c
modules_k/presence/utils_func.c
modules_k/presence/utils_func.h

index 57d69af..9e6f341 100644 (file)
@@ -496,7 +496,7 @@ unsupported_event:
        if(msg->event && msg->event->body.s && msg->event->body.len>0)
                LM_ERR("\tevent=[%.*s]\n", msg->event->body.len, msg->event->body.s);
 
-       reply_code= 489;
+       reply_code= BAD_EVENT_CODE;
        reply_str=      pu_489_rpl; 
 
 error:
index e18ed2c..b1658ae 100644 (file)
@@ -674,7 +674,7 @@ bad_event:
        if(parsed_event)
                LM_ERR("\tevent= %.*s\n",parsed_event->text.len,parsed_event->text.s);
        
-       reply_code= 489;
+       reply_code= BAD_EVENT_CODE;
        reply_str= pu_489_rpl;
 
 error:
index 2df2930..87da4a2 100644 (file)
@@ -96,7 +96,7 @@ int a_to_i (char *s,int len)
 
 int send_error_reply(struct sip_msg* msg, int reply_code, str reply_str)
 {
-       if(reply_code== 481)
+       if(reply_code== BAD_EVENT_CODE)
        {
                str hdr_append;
                char buffer[256];
index 01ce61f..394c86f 100644 (file)
@@ -38,6 +38,7 @@
 #include "../../parser/msg_parser.h"
 
 #define LCONTACT_BUF_SIZE 1024
+#define BAD_EVENT_CODE 489
 
 static inline int uandd_to_uri(str user,  str domain, str *out)
 {