]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-9705 regression 2
authorAnthony Minessale <anthm@freeswitch.org>
Wed, 16 Nov 2016 17:23:19 +0000 (11:23 -0600)
committerAnthony Minessale <anthm@freeswitch.org>
Wed, 16 Nov 2016 17:23:19 +0000 (11:23 -0600)
src/switch_core_file.c

index 84fb607398570be1b61ada3462d932fd0ddea3ac..46ee5390b981e48cef9cd31c1966a1fcd0151542 100644 (file)
@@ -392,7 +392,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_file_read(switch_file_handle_t *fh,
                return SWITCH_STATUS_FALSE;
        }
 
-       if (*len && fh->buffer && switch_buffer_inuse(fh->buffer) >= *len * 2 * fh->channels) {
+       if (fh->buffer && switch_buffer_inuse(fh->buffer) >= *len * 2 * fh->channels) {
                *len = switch_buffer_read(fh->buffer, data, orig_len * 2 * fh->channels) / 2 / fh->channels;
                return *len == 0 ? SWITCH_STATUS_FALSE : SWITCH_STATUS_SUCCESS;
        }