Commit 1cc7a5c9 authored by Laurent Aimar's avatar Laurent Aimar

Fixed support for multi-volume archive.

09d1c6e1 was not working...

It fixes #6190.
parent 1c23e3df
...@@ -327,7 +327,7 @@ int RarParse(stream_t *s, int *count, rar_file_t ***file) ...@@ -327,7 +327,7 @@ int RarParse(stream_t *s, int *count, rar_file_t ***file)
} }
/* */ /* */
bool has_next = false; int has_next = 1;
for (;;) { for (;;) {
rar_block_t bk; rar_block_t bk;
int ret; int ret;
...@@ -350,11 +350,12 @@ int RarParse(stream_t *s, int *count, rar_file_t ***file) ...@@ -350,11 +350,12 @@ int RarParse(stream_t *s, int *count, rar_file_t ***file)
if (ret) if (ret)
break; break;
} }
if (has_next < 0)
has_next = *count > 0 && !(*file)[*count -1]->is_complete;
if (vol != s) if (vol != s)
stream_Delete(vol); stream_Delete(vol);
if (!has_next || !pattern || if (!has_next || !pattern) {
(*count > 0 && !(*file)[*count -1]->is_complete)) {
free(volume_mrl); free(volume_mrl);
return VLC_SUCCESS; return VLC_SUCCESS;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment