[GRASS-SVN] r53552 - grass/trunk/vector/v.transform
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Oct 25 08:21:47 PDT 2012
Author: mmetz
Date: 2012-10-25 08:21:43 -0700 (Thu, 25 Oct 2012)
New Revision: 53552
Modified:
grass/trunk/vector/v.transform/trans_digit.c
Log:
v.transform: fix memory issues
Modified: grass/trunk/vector/v.transform/trans_digit.c
===================================================================
--- grass/trunk/vector/v.transform/trans_digit.c 2012-10-25 14:41:09 UTC (rev 53551)
+++ grass/trunk/vector/v.transform/trans_digit.c 2012-10-25 15:21:43 UTC (rev 53552)
@@ -31,6 +31,7 @@
Cats = Vect_new_cats_struct();
driver = NULL;
+ fi = NULL;
if (field > 0) {
fi = Vect_get_field(Old, field);
@@ -39,7 +40,7 @@
G_fatal_error(_("Unable to open database <%s> by driver <%s>"),
fi->database, fi->driver);
- trans_params = (double *)G_calloc(IDX_ZROT, sizeof(double));
+ trans_params = (double *)G_calloc(IDX_ZROT + 1, sizeof(double));
}
else {
trans_params = trans_params_def;
More information about the grass-commit
mailing list