tatsuhiro-t/aria2 — pull request #48 by nmaier (2013-02-25 19:52:12+00:00)
Title: Detect console with on Windows

Windows, too, has an API for determining the actual console width.

Don't ask me about the -2. I did the patch a couple of month back and remember this was required for whatever reason (instead of just -1).