mIRC Homepage
Posted By: Venom_IL Resume rollback - 23/09/03 09:38 AM
resume roll back means that when a download is resumed, its not resumed from the exact same spot it stopped, but rather some odd 20 KB's before that. this prevents download corruption (from packets sent from dying bots, internet connection errors etc) and works very well in DC++. the only IRC Client that supports this AFAIK is HydraIRC but it lacks other things. would be great if anyone knows of a client that supports this feature and the "/timer" one, at least until its implemented in mIRC which is my favorite wink

Thanks =)
Posted By: Raccoon Re: Resume rollback - 23/09/03 01:49 PM
You could write your own rollback with a bit of effort.

When the DCC fails, remove 20K off the top of the file and resume the DCC.

/btrunc $filename $iif($calc($file($filename).size - 20 * 1024 ) > 0, $ifmatch, 0)

If you wish to verify the integrity of the old data to the resume data, dump the 20K to a temporary file and note the size (position) of the file you're resuming. You can then read the temporary file and the 20K sector of the new file into Binary Variables and compare them with $crc or $md5 (I'd use $crc because $md5 has a bug). This can be done after the DCC completes or after 20K has been resumed while it still downloads.

I'm not sure what you mean by "/timer one".

- Raccoon
Posted By: v0id Re: Resume rollback - 23/09/03 01:57 PM
40.A dcc resume now chops off the last 8192 bytes of a file in case
the end of the file was corrupted during a previous transfer.

versions.txt
Posted By: Venom_IL Re: Resume rollback - 23/09/03 02:28 PM
well apparantly 8 k isn't enough.. as ive had my share of corrupted downloads..

didnt notice it in the changelog though because i was looking for "rollback".. impossible for me to guess what the devs would call it and its quite a long list, so i just tried the "official" term but thanks for the info

Raccoon - the entire idea is that it's done automatically.. chopping off 20 k isn't the hard part and there's even a simple prog that does just that and its called, well, "cutoff"

is there a way to script automatic cutoff upon a failed dcc ?

btw, by "/timer" i mean just that - the mIRC /timer command, i.e. im looking for a client with both rollback and a command equivelent to mIRC's /timer, assuming it can't be done through mIRC

thanks :tongue:

Posted By: Raccoon Re: Resume rollback - 23/09/03 02:57 PM
On *:GETFAIL:*: {
btrunc $filename $iif($calc($file($filename).size - 20 * 1024 ) > 0, $ifmatch, 0)
}
Posted By: Venom_IL Re: Resume rollback - 24/09/03 05:48 AM
forgive me for my great n00bness, but where do i put this ? grin

will it work EVERY time, whenever ANY file failes ? even if the same file failes twice etc ?

thanks wink

Posted By: sparta Re: Resume rollback - 24/09/03 05:55 AM
You put it in your Remote.. ALT + R open the remote section..
Posted By: Raccoon Re: Resume rollback - 24/09/03 07:50 AM
... and yes, every time.

It truncates 20K off the file, each time a download or resume fails. This may or may not include an additional 5K as was pointed out above when mIRC actually begins resuming.

- Raccoon
Posted By: Venom_IL Re: Resume rollback - 24/09/03 11:17 AM
You people are class A smile

so let me get this straight - i just paste this exact text:

On *:GETFAIL:*: {
btrunc $filename $iif($calc($file($filename).size - 100 * 1024 ) > 0, $ifmatch, 0)
}

in the ALT+R window (mIRC editor, Remote) press ok and that's all there is to it ?

(Notice I changed it to 100K, what can I say I'm a paranoid grin )
Posted By: Raccoon Re: Resume rollback - 24/09/03 09:10 PM
You've got it.

Note, I haven't actually tested the code, but I'm pretty confident it works.

Let me know if it starts a fire or anything. grin
Posted By: Venom_IL Re: Resume rollback - 24/09/03 10:22 PM
You be da man

at first it didnt work, but then i checked "monitor file changes", listen to "ctcp", "events", "raw"

so proud of myself that i found it out all alone grin

you know its funny, ive been looking for this feature for about a month, trying a zillion clients, begging hydra to add the "/timer" command (he had rollback but without /timer a client is useless to me).. scouring google etc.. when all of this time it couldve been done so simply...

Thanks again, and maximum respect cool
© mIRC Discussion Forums