Explorar el Código

Free unused memory

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@58623 15284696-431f-4ddb-bdfa-cd5b030d7da7
Pietro Zambelli hace 11 años
padre
commit
62db2eca32
Se han modificado 1 ficheros con 4 adiciones y 3 borrados
  1. 4 3
      lib/python/pygrass/modules/grid/patch.py

+ 4 - 3
lib/python/pygrass/modules/grid/patch.py

@@ -57,7 +57,8 @@ def rpatch_map(raster, mapset, mset_str, bbox_list, overwrite=False,
         rasts.append(rrasts)
         rpatch_row(rast, rrasts, rbbox)
 
-    for rrast in rasts:
-        for rast_ in rrast:
-            rast_.close()
+        for rst in rrasts:
+            rst.close()
+            del(rst)
+
     rast.close()