]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
[Core] Remove dead assignment and dead increment in text_bridge_thread(). 264/head
authorAndrey Volk <andywolk@gmail.com>
Sun, 26 Jan 2020 14:07:15 +0000 (18:07 +0400)
committerAndrey Volk <andywolk@gmail.com>
Sun, 26 Jan 2020 14:07:15 +0000 (18:07 +0400)
src/switch_ivr_bridge.c

index 5ff242e102ca127cce6819c2a70c7377bf293880..7acfd0cd608c8ecf264ef6ef1c61136eb75d5396 100644 (file)
@@ -80,7 +80,7 @@ static void text_bridge_thread(switch_core_session_t *session, void *obj)
                        inuse = switch_buffer_inuse(text_buffer);
 
                        if (inuse && (switch_channel_test_flag(channel, CF_TEXT_IDLE) || switch_test_flag(read_frame, SFF_TEXT_LINE_BREAK))) {
-                               int bytes = 0;
+                               int bytes;
 
                                if (inuse + 4 > text_framesize) {
                                        void *tmp = malloc(inuse + 1024);
@@ -114,7 +114,6 @@ static void text_bridge_thread(switch_core_session_t *session, void *obj)
                                *(text_framedata + bytes) = '\r';
                                *(text_framedata + bytes + 1) = '\n';
                                *(text_framedata + bytes + 2) = '\0';
-                               bytes += 2;
 
                                frame.data = text_framedata;
                                frame.datalen = strlen((char *)frame.data);