<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -174,8 +174,13 @@ class MyURLopener(urllib.FancyURLopener):
         if localsize &lt; self.checksum_size:
             self.checksum_size = localsize
         seekto = localsize - self.checksum_size
+
+        # set var read in open_ftp()
         os.environ[&quot;REST&quot;] = str(seekto)
+
+        # set header for http
         self.set_header(('Range', 'bytes=%s-' % seekto))
+
         return localsize
 
     # Override function from urllib to support resuming transfers
@@ -589,7 +594,7 @@ class Fetcher(object):
 
 
 if __name__ == &quot;__main__&quot;:
-    (parser, a) = io.init_opts(&quot;&lt;url&gt; [&lt;file&gt;] [options]&quot;)
+    (parser, a) = io.init_opts(&quot;&lt;url&gt;+ [options]&quot;)
     a(&quot;--spidertest&quot;, action=&quot;store_true&quot;, help=&quot;Test spider with url&quot;)
     (opts, args) = io.parse_args(parser)
     try:
@@ -600,12 +605,16 @@ if __name__ == &quot;__main__&quot;:
             Fetcher(mode=Fetcher.SPIDER, url=url, filename=filename).launch()
             os.close(fp) ; os.unlink(filename)
         else:
-            if len(args) &gt; 1:
-                filename = args[1]
-            else:
-                os.environ[&quot;ORIG_FILENAMES&quot;] = os.environ.get(&quot;ORIG_FILENAMES&quot;) or &quot;1&quot;
+            args = list(args)
+            args.reverse()
+            os.environ[&quot;ORIG_FILENAMES&quot;] = os.environ.get(&quot;ORIG_FILENAMES&quot;) or &quot;1&quot;
+            while args:
+                url = args.pop()
                 filename = urlrewrite.url_to_filename(url)
-            Fetcher(mode=Fetcher.FETCH, url=url, filename=filename).launch()
+                try:
+                    Fetcher(mode=Fetcher.FETCH, url=url, filename=filename).launch()
+                except Exception, e:
+                    print e
     except filetype.WrongFileTypeError:
         os.unlink(filename)
     except KeyboardInterrupt:</diff>
      <filename>fetch.py</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>33d69373f5e6736f7abc115d12c3a214a44f898e</id>
    </parent>
  </parents>
  <author>
    <name>Martin Matusiak</name>
    <email>numerodix@gmail.com</email>
  </author>
  <url>http://github.com/numerodix/spiderfetch/commit/2e7260239892a7453f1148c3da8a73663daffd7a</url>
  <id>2e7260239892a7453f1148c3da8a73663daffd7a</id>
  <committed-date>2008-06-29T13:31:38-07:00</committed-date>
  <authored-date>2008-06-29T13:31:38-07:00</authored-date>
  <message>fetch: add support for multiple urls on cmd line</message>
  <tree>333ebee39b493522c9295d326f59861bd9ba8a98</tree>
  <committer>
    <name>Martin Matusiak</name>
    <email>numerodix@gmail.com</email>
  </committer>
</commit>
