Make GzipFile an iterator.  Closes bug #532621.
diff --git a/Lib/gzip.py b/Lib/gzip.py
index 74c0d26..9e9f5d4 100644
--- a/Lib/gzip.py
+++ b/Lib/gzip.py
@@ -351,6 +351,16 @@
         for line in L:
             self.write(line)
 
+    def __iter__(self):
+        return self
+
+    def next(self):
+        line = self.readline()
+        if line:
+            return line
+        else:
+            raise StopIteration
+
 
 def _test():
     # Act like gzip; with -d, act like gunzip.