Closed ghost closed 5 years ago
all right, downloadComplete
listener is invoked when last piece is received and validated. I think we need listener like validationComplete(int validpieces, int totalpieces)
and if this method was invoked with validpieces == totalpieces
thenclient.downloadTorrent()
method must finished. I will try to fix it
fixed
The following code fails to complete if the file already exists.
Tried to debug it and it seems like the downloadComplete isn't called if the file already exists. It is called otherwise.
Following logs for when it works:
Following logs for when it doesn't: