Explorar el Código

bugfix: G__create_alt_env

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@35467 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa hace 16 años
padre
commit
3077a2d1f0
Se han modificado 1 ficheros con 5 adiciones y 3 borrados
  1. 5 3
      lib/gis/env.c

+ 5 - 3
lib/gis/env.c

@@ -518,10 +518,12 @@ void G__create_alt_env(void)
     int i;
 
     /* copy env to env2 */
-    st->env2 = st->env;
-
+    G_copy(&st->env2, &st->env, sizeof(st->env));
+    
     st->env.count = 0;
-
+    st->env.size = 0;
+    st->env.binds = NULL;
+    
     for (i = 0; i < st->env2.count; i++) {
 	struct bind *b = &st->env2.binds[i];
 	if (b->name)