<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[Freeswitch-trunk][16819] </title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<div id="header">FreeSWITCH Subversion</div>
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://fisheye.freeswitch.org/changelog/FreeSWITCH?cs=16819">16819</a></dd>
<dt>Author</dt> <dd>sathieu</dd>
<dt>Date</dt> <dd>2010-02-25 08:34:43 -0600 (Thu, 25 Feb 2010)</dd>
</dl>
<h3>Log Message</h3>
<pre>Skinny: add send Reset/Restart</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#freeswitchtrunksrcmodendpointsmod_skinnymod_skinnyc">freeswitch/trunk/src/mod/endpoints/mod_skinny/mod_skinny.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_skinnyskinny_protocolc">freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_skinnyskinny_protocolh">freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.h</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="freeswitchtrunksrcmodendpointsmod_skinnymod_skinnyc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_skinny/mod_skinny.c (16818 => 16819)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_skinny/mod_skinny.c        2010-02-25 13:56:11 UTC (rev 16818)
+++ freeswitch/trunk/src/mod/endpoints/mod_skinny/mod_skinny.c        2010-02-25 14:34:43 UTC (rev 16819)
</span><span class="lines">@@ -1545,6 +1545,25 @@
</span><span class="cx">         return SWITCH_STATUS_SUCCESS;
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+static switch_status_t cmd_profile_device_send_reset_message(const char *profile_name, const char *device_name, const char *reset_type, switch_stream_handle_t *stream)
+{
+        skinny_profile_t *profile;
+
+        if ((profile = skinny_find_profile(profile_name))) {
+                listener_t *listener = NULL;
+                skinny_profile_find_listener_by_device_name(profile, device_name, &listener);
+                if(listener) {
+                        send_reset(listener, skinny_str2device_reset_type(reset_type));
+                } else {
+                        stream->write_function(stream, "Listener not found!\n");
+                }
+        } else {
+                stream->write_function(stream, "Profile not found!\n");
+        }
+
+        return SWITCH_STATUS_SUCCESS;
+}
+
</ins><span class="cx"> SWITCH_STANDARD_API(skinny_function)
</span><span class="cx"> {
</span><span class="cx">         char *argv[1024] = { 0 };
</span><span class="lines">@@ -1556,10 +1575,11 @@
</span><span class="cx">                 "skinny help\n"
</span><span class="cx">                 "skinny status profile <profile_name>\n"
</span><span class="cx">                 "skinny status profile <profile_name> device <device_name>\n"
</span><ins>+                "skinny profile <profile_name> device <device_name> send ResetMessage [DeviceReset|DeviceRestart]\n"
</ins><span class="cx">                 "skinny profile <profile_name> device <device_name> send SetRingerMessage <ring_type> <ring_mode>\n"
</span><span class="cx">                 "skinny profile <profile_name> device <device_name> send SetLampMessage <stimulus> <instance> <lamp_mode>\n"
</span><span class="cx">                 "skinny profile <profile_name> device <device_name> send SetSpeakerModeMessage <speaker_mode>\n"
</span><del>-                "skinny profile <profile_name> device <device_name> send CallState <call_state> <line_instance> <call_id>\n"
</del><ins>+                "skinny profile <profile_name> device <device_name> send CallStateMessage <call_state> <line_instance> <call_id>\n"
</ins><span class="cx">                 "--------------------------------------------------------------------------------\n";
</span><span class="cx">         if (session) {
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="lines">@@ -1589,18 +1609,42 @@
</span><span class="cx">         } else if (argc == 5 && !strcasecmp(argv[0], "status") && !strcasecmp(argv[1], "profile") && !strcasecmp(argv[3], "device")) {
</span><span class="cx">                 /* skinny status profile <profile_name> device <device_name> */
</span><span class="cx">                 status = cmd_status_profile_device(argv[2], argv[4], stream);
</span><del>-        } else if (argc == 8 && !strcasecmp(argv[0], "profile") && !strcasecmp(argv[2], "device") && !strcasecmp(argv[4], "send") && !strcasecmp(argv[5], "SetRingerMessage")) {
-                /* skinny profile <profile_name> device <device_name> send SetRingerMessage <stimulus> <instance> <lamp_mode> */
-                status = cmd_profile_device_send_ringer_message(argv[1], argv[3], argv[6], argv[7], stream);
-        } else if (argc == 9 && !strcasecmp(argv[0], "profile") && !strcasecmp(argv[2], "device") && !strcasecmp(argv[4], "send") && !strcasecmp(argv[5], "SetLampMessage")) {
-                /* skinny profile <profile_name> device <device_name> send SetLampMessage <stimulus> <instance> <lamp_mode> */
-                status = cmd_profile_device_send_lamp_message(argv[1], argv[3], argv[6], argv[7], argv[8], stream);
-        } else if (argc == 7 && !strcasecmp(argv[0], "profile") && !strcasecmp(argv[2], "device") && !strcasecmp(argv[4], "send") && !strcasecmp(argv[5], "SetSpeakerModeMessage")) {
-                /* skinny profile <profile_name> device <device_name> send SetSpeakerModeMessage <speaker_mode> */
-                status = cmd_profile_device_send_speaker_mode_message(argv[1], argv[3], argv[6], stream);
-        } else if (argc == 9 && !strcasecmp(argv[0], "profile") && !strcasecmp(argv[2], "device") && !strcasecmp(argv[4], "send") && !strcasecmp(argv[5], "CallState")) {
-                /* skinny profile <profile_name> device <device_name> send CallState <call_state> <line_instance> <call_id> */
-                status = cmd_profile_device_send_call_state_message(argv[1], argv[3], argv[6], argv[7], argv[8], stream);
</del><ins>+        } else if (argc >= 6 && !strcasecmp(argv[0], "profile") && !strcasecmp(argv[2], "device") && !strcasecmp(argv[4], "send")) {
+                /* skinny profile <profile_name> device <device_name> send ... */
+                switch(skinny_str2message_type(argv[5])) {
+                        case SET_RINGER_MESSAGE:
+                                if(argc == 8) {
+                                        /* SetRingerMessage <ring_type> <ring_mode> */
+                                        status = cmd_profile_device_send_ringer_message(argv[1], argv[3], argv[6], argv[7], stream);
+                                }
+                                break;
+                        case SET_LAMP_MESSAGE:
+                                if (argc == 9) {
+                                        /* SetLampMessage <stimulus> <instance> <lamp_mode> */
+                                        status = cmd_profile_device_send_lamp_message(argv[1], argv[3], argv[6], argv[7], argv[8], stream);
+                                }
+                                break;
+                        case SET_SPEAKER_MODE_MESSAGE:
+                                if (argc == 7) {
+                                        /* SetSpeakerModeMessage <speaker_mode> */
+                                        status = cmd_profile_device_send_speaker_mode_message(argv[1], argv[3], argv[6], stream);
+                                }
+                                break;
+                        case CALL_STATE_MESSAGE:
+                                if (argc == 9) {
+                                        /* CallStateMessage <call_state> <line_instance> <call_id> */
+                                        status = cmd_profile_device_send_call_state_message(argv[1], argv[3], argv[6], argv[7], argv[8], stream);
+                                }
+                                break;
+                        case RESET_MESSAGE:
+                                if (argc == 7) {
+                                        /* ResetMessage <reset_type> */
+                                        status = cmd_profile_device_send_reset_message(argv[1], argv[3], argv[6], stream);
+                                }
+                                break;
+                        default:
+                                stream->write_function(stream, "Unhandled message %s\n", argv[5]);
+                }
</ins><span class="cx">         } else {
</span><span class="cx">                 stream->write_function(stream, "Unknown Command [%s]\n", argv[0]);
</span><span class="cx">         }
</span><span class="lines">@@ -1694,6 +1738,13 @@
</span><span class="cx">         return status;
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+static switch_status_t skinny_list_reset_types(const char *line, const char *cursor, switch_console_callback_match_t **matches)
+{
+        switch_status_t status = SWITCH_STATUS_FALSE;
+        SKINNY_PUSH_DEVICE_RESET_TYPES
+        return status;
+}
+
</ins><span class="cx"> static switch_status_t skinny_list_stimuli(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</span><span class="cx"> {
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="lines">@@ -1701,14 +1752,14 @@
</span><span class="cx">         return status;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static switch_status_t skinny_list_ring_type(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</del><ins>+static switch_status_t skinny_list_ring_types(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</ins><span class="cx"> {
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">         SKINNY_PUSH_RING_TYPES
</span><span class="cx">         return status;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static switch_status_t skinny_list_ring_mode(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</del><ins>+static switch_status_t skinny_list_ring_modes(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</ins><span class="cx"> {
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">         SKINNY_PUSH_RING_MODES
</span><span class="lines">@@ -1737,7 +1788,7 @@
</span><span class="cx">         return status;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static switch_status_t skinny_list_speaker_mode(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</del><ins>+static switch_status_t skinny_list_speaker_modes(const char *line, const char *cursor, switch_console_callback_match_t **matches)
</ins><span class="cx"> {
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">         SKINNY_PUSH_SPEAKER_MODES
</span><span class="lines">@@ -1830,19 +1881,21 @@
</span><span class="cx">         switch_console_set_complete("add skinny status profile ::skinny::list_profiles");
</span><span class="cx">         switch_console_set_complete("add skinny status profile ::skinny::list_profiles device ::skinny::list_devices");
</span><span class="cx">
</span><del>-        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send SetRingerMessage ::skinny::list_ring_type ::skinny::list_ring_mode");
</del><ins>+        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send ResetMessage ::skinny::list_reset_types");
+        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send SetRingerMessage ::skinny::list_ring_types ::skinny::list_ring_modes");
</ins><span class="cx">         switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send SetLampMessage ::skinny::list_stimuli ::skinny::list_stimulus_instances ::skinny::list_stimulus_modes");
</span><del>-        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send SetSpeakerModeMessage ::skinny::list_speaker_mode");
-        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send CallState ::skinny::list_call_states ::skinny::list_line_instances ::skinny::list_call_ids");
</del><ins>+        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send SetSpeakerModeMessage ::skinny::list_speaker_modes");
+        switch_console_set_complete("add skinny profile ::skinny::list_profiles device ::skinny::list_devices send CallStateMessage ::skinny::list_call_states ::skinny::list_line_instances ::skinny::list_call_ids");
</ins><span class="cx">
</span><span class="cx">         switch_console_add_complete_func("::skinny::list_profiles", skinny_list_profiles);
</span><span class="cx">         switch_console_add_complete_func("::skinny::list_devices", skinny_list_devices);
</span><del>-        switch_console_add_complete_func("::skinny::list_ring_type", skinny_list_ring_type);
-        switch_console_add_complete_func("::skinny::list_ring_mode", skinny_list_ring_mode);
</del><ins>+        switch_console_add_complete_func("::skinny::list_reset_types", skinny_list_reset_types);
+        switch_console_add_complete_func("::skinny::list_ring_types", skinny_list_ring_types);
+        switch_console_add_complete_func("::skinny::list_ring_modes", skinny_list_ring_modes);
</ins><span class="cx">         switch_console_add_complete_func("::skinny::list_stimuli", skinny_list_stimuli);
</span><span class="cx">         switch_console_add_complete_func("::skinny::list_stimulus_instances", skinny_list_stimulus_instances);
</span><span class="cx">         switch_console_add_complete_func("::skinny::list_stimulus_modes", skinny_list_stimulus_modes);
</span><del>-        switch_console_add_complete_func("::skinny::list_speaker_mode", skinny_list_speaker_mode);
</del><ins>+        switch_console_add_complete_func("::skinny::list_speaker_modes", skinny_list_speaker_modes);
</ins><span class="cx">         switch_console_add_complete_func("::skinny::list_call_states", skinny_list_call_states);
</span><span class="cx">         switch_console_add_complete_func("::skinny::list_line_instances", skinny_list_line_instances);
</span><span class="cx">         switch_console_add_complete_func("::skinny::list_call_ids", skinny_list_call_ids);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_skinnyskinny_protocolc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.c (16818 => 16819)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.c        2010-02-25 13:56:11 UTC (rev 16818)
+++ freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.c        2010-02-25 14:34:43 UTC (rev 16819)
</span><span class="lines">@@ -76,7 +76,7 @@
</span><span class="cx">         {"AlarmMessage", ALARM_MESSAGE},
</span><span class="cx">         {"OpenReceiveChannelAckMessage", OPEN_RECEIVE_CHANNEL_ACK_MESSAGE},
</span><span class="cx">         {"SoftKeySetReqMessage", SOFT_KEY_SET_REQ_MESSAGE},
</span><del>-        {"SOftKeyEventMessage", SOFT_KEY_EVENT_MESSAGE},
</del><ins>+        {"SoftKeyEventMessage", SOFT_KEY_EVENT_MESSAGE},
</ins><span class="cx">         {"UnregisterMessage", UNREGISTER_MESSAGE},
</span><span class="cx">         {"SoftKeyTemplateReqMessage", SOFT_KEY_TEMPLATE_REQ_MESSAGE},
</span><span class="cx">         {"FeatureStatReqMessage", FEATURE_STAT_REQ_MESSAGE},
</span><span class="lines">@@ -98,7 +98,8 @@
</span><span class="cx">         {"ButtonTemplateResMessage", BUTTON_TEMPLATE_RES_MESSAGE},
</span><span class="cx">         {"CapabilitiesReqMessage", CAPABILITIES_REQ_MESSAGE},
</span><span class="cx">         {"RegisterRejMessage", REGISTER_REJ_MESSAGE},
</span><del>-        {"KeepAliveAckMessageMessage", KEEP_ALIVE_ACK_MESSAGE},
</del><ins>+        {"ResetMessage", RESET_MESSAGE},
+        {"KeepAliveAckMessage", KEEP_ALIVE_ACK_MESSAGE},
</ins><span class="cx">         {"OpenReceiveChannelMessage", OPEN_RECEIVE_CHANNEL_MESSAGE},
</span><span class="cx">         {"OCloseReceiveChannelMessage", CLOSE_RECEIVE_CHANNEL_MESSAGE},
</span><span class="cx">         {"SoftKeyTemplateResMessage", SOFT_KEY_TEMPLATE_RES_MESSAGE},
</span><span class="lines">@@ -198,6 +199,15 @@
</span><span class="cx"> };
</span><span class="cx"> SKINNY_DECLARE_ID2STR(skinny_call_state2str, SKINNY_CALL_STATES, "CallStateUnknown")
</span><span class="cx"> SKINNY_DECLARE_STR2ID(skinny_str2call_state, SKINNY_CALL_STATES, -1)
</span><ins>+
+struct skinny_table SKINNY_DEVICE_RESET_TYPES[] = {
+        {"DeviceReset", SKINNY_DEVICE_RESET},
+        {"DeviceRestart", SKINNY_DEVICE_RESTART},
+        {NULL, 0}
+};
+SKINNY_DECLARE_ID2STR(skinny_device_reset_type2str, SKINNY_DEVICE_RESET_TYPES, "DeviceResetTypeUnknown")
+SKINNY_DECLARE_STR2ID(skinny_str2device_reset_type, SKINNY_DEVICE_RESET_TYPES, -1)
+
</ins><span class="cx"> /*****************************************************************************/
</span><span class="cx"> /* SKINNY FUNCTIONS */
</span><span class="cx"> /*****************************************************************************/
</span><span class="lines">@@ -1081,6 +1091,18 @@
</span><span class="cx">         return SWITCH_STATUS_SUCCESS;
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+switch_status_t send_reset(listener_t *listener,
+        uint32_t reset_type)
+{
+        skinny_message_t *message;
+        message = switch_core_alloc(listener->pool, 12+sizeof(message->data.reset));
+        message->type = RESET_MESSAGE;
+        message->length = 4 + sizeof(message->data.reset);
+        message->data.reset.reset_type = reset_type;
+        skinny_send_reply(listener, message);
+        return SWITCH_STATUS_SUCCESS;
+}
+
</ins><span class="cx"> /* Message handling */
</span><span class="cx"> switch_status_t skinny_handle_alarm(listener_t *listener, skinny_message_t *request)
</span><span class="cx"> {
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_skinnyskinny_protocolh"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.h (16818 => 16819)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.h        2010-02-25 13:56:11 UTC (rev 16818)
+++ freeswitch/trunk/src/mod/endpoints/mod_skinny/skinny_protocol.h        2010-02-25 14:34:43 UTC (rev 16819)
</span><span class="lines">@@ -342,6 +342,12 @@
</span><span class="cx">         char error[33];
</span><span class="cx"> };
</span><span class="cx">
</span><ins>+/* ResetMessage */
+#define RESET_MESSAGE 0x009F
+struct reset_message {
+        uint32_t reset_type; /* See enum skinny_device_reset_types */
+};
+
</ins><span class="cx"> /* KeepAliveAckMessage */
</span><span class="cx"> #define KEEP_ALIVE_ACK_MESSAGE 0x0100
</span><span class="cx">
</span><span class="lines">@@ -490,6 +496,7 @@
</span><span class="cx">         struct define_time_date_message define_time_date;
</span><span class="cx">         struct button_template_message button_template;
</span><span class="cx">         struct register_rej_message reg_rej;
</span><ins>+        struct reset_message reset;
</ins><span class="cx">         struct open_receive_channel_message open_receive_channel;
</span><span class="cx">         struct close_receive_channel_message close_receive_channel;
</span><span class="cx">         struct soft_key_template_res_message soft_key_template;
</span><span class="lines">@@ -612,7 +619,7 @@
</span><span class="cx">                 status = SWITCH_STATUS_SUCCESS;\
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-struct skinny_table SKINNY_MESSAGE_TYPES[51];
</del><ins>+struct skinny_table SKINNY_MESSAGE_TYPES[52];
</ins><span class="cx"> const char *skinny_message_type2str(uint32_t id);
</span><span class="cx"> uint32_t skinny_str2message_type(const char *str);
</span><span class="cx"> #define SKINNY_PUSH_MESSAGE_TYPES SKINNY_DECLARE_PUSH_MATCH(SKINNY_MESSAGE_TYPES)
</span><span class="lines">@@ -749,6 +756,15 @@
</span><span class="cx"> uint32_t skinny_str2call_state(const char *str);
</span><span class="cx"> #define SKINNY_PUSH_CALL_STATES SKINNY_DECLARE_PUSH_MATCH(SKINNY_CALL_STATES)
</span><span class="cx">
</span><ins>+enum skinny_device_reset_types {
+ SKINNY_DEVICE_RESET = 1,
+ SKINNY_DEVICE_RESTART = 2
+};
+struct skinny_table SKINNY_DEVICE_RESET_TYPES[3];
+const char *skinny_device_reset_type2str(uint32_t id);
+uint32_t skinny_str2device_reset_type(const char *str);
+#define SKINNY_PUSH_DEVICE_RESET_TYPES SKINNY_DECLARE_PUSH_MATCH(SKINNY_DEVICE_RESET_TYPES)
+
</ins><span class="cx"> /*****************************************************************************/
</span><span class="cx"> /* SKINNY FUNCTIONS */
</span><span class="cx"> /*****************************************************************************/
</span><span class="lines">@@ -869,6 +885,8 @@
</span><span class="cx">         char called_party[24],
</span><span class="cx">         uint32_t line_instance,
</span><span class="cx">         uint32_t call_id);
</span><ins>+switch_status_t send_reset(listener_t *listener,
+        uint32_t reset_type);
</ins><span class="cx">
</span><span class="cx"> #endif /* _SKINNY_PROTOCOL_H */
</span><span class="cx">
</span></span></pre>
</div>
</div>
<div id="footer">See you at ClueCon</div>
</body>
</html>