Use time window for ETA computation

Keep information about current transfer speed in time window to properly
estimate finish time.

sxcp progress handling cosmetics (braces && indentation).
Code cosmetics

Change indentation.
Silence compiler warnings.
Change few local variables types from int to unsigned int that are used as array indices. That stops warnings about comparing signed and unsigned variables.
Print progress information to stderr instead of stdout

Summaries are printed to stdout