Browse code

core: added info method to AmSipDialog

Juha Heinanen authored on 08/05/2014 18:29:55
Showing 2 changed files
... ...
@@ -641,6 +641,17 @@ int AmSipDialog::refer(const string& refer_to,
641 641
   }	
642 642
 }
643 643
 
644
+int AmSipDialog::info(const string& hdrs, const AmMimeBody* body)
645
+{
646
+  if(getStatus() == Connected) {
647
+    return sendRequest("INFO", body, hdrs);
648
+  } else {
649
+    DBG("info(): we are not Connected."
650
+	"(status=%s). do nothing!\n", getStatusStr());
651
+    return 0;
652
+  }
653
+}    
654
+
644 655
 // proprietary
645 656
 int AmSipDialog::transfer(const string& target)
646 657
 {
... ...
@@ -136,6 +136,10 @@ protected:
136 136
 	    int expires = -1,
137 137
 	    const string& referred_by = "");
138 138
 
139
+  /** @return 0 on success */
140
+  int info(const string& hdrs,  
141
+	   const AmMimeBody* body);
142
+
139 143
   /** @return 0 on success */
140 144
   int transfer(const string& target);
141 145
   int drop();