Unified · Split
| @@ -445,9 +445,10 @@ static int stopwrite(sox_format_t * ft) · 444 unmodified lines | |||
| 445 | int rc = SOX_SUCCESS; | 445 | int rc = SOX_SUCCESS; |
| 446 | 446 | ||
| 447 | /* Compress it all at once */ | 447 | /* Compress it all at once */ |
| 448 | if (compressed_len) | 448 | if (compressed_len) { |
| 449 | compress(ft, &compressed_data, (int32_t *)&compressed_len); | 449 | compress(ft, &compressed_data, (int32_t *)&compressed_len); |
| 450 | free(p->data); | 450 | free(p->data); |
| 451 | } | ||
| 451 | 452 | ||
| 452 | /* Write the header */ | 453 | /* Write the header */ |
| 453 | lsx_writebuf(ft, "\000\001A", (size_t) 3); /* Dummy file name "A" */ | 454 | lsx_writebuf(ft, "\000\001A", (size_t) 3); /* Dummy file name "A" */ |