[GRASS-SVN] r31547 -
grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed May 28 09:31:04 EDT 2008
Author: neteler
Date: 2008-05-28 09:31:03 -0400 (Wed, 28 May 2008)
New Revision: 31547
Modified:
grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/daemon.c
grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/ipc.h
grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/main.c
Log:
don't hardcode G*_MAX buffer lengths
Modified: grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/daemon.c
===================================================================
--- grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/daemon.c 2008-05-28 13:19:50 UTC (rev 31546)
+++ grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/daemon.c 2008-05-28 13:31:03 UTC (rev 31547)
@@ -37,7 +37,7 @@
int calculateIndex(char *file, int f(int, char **, area_des, double *),\
char** parameters, char *raster, char *output){
- char pathSetup[150],out[150], parsed;
+ char pathSetup[GPATH_MAX],out[GPATH_MAX], parsed;
char * reportChannelName, * random_access_name;
struct History history;
g_areas g;
@@ -272,7 +272,7 @@
int parseSetup(char *path, list l, g_areas g, char *raster){
struct stat s;
struct Cell_head cellhd;
- char * buf, *token, *mapset;/* g_region[350]; */
+ char * buf, *token, *mapset;
int setup;
int letti;
double rel_x, rel_y, rel_rl, rel_cl;
@@ -368,7 +368,7 @@
else if (strcmp("MASKEDSAMPLEAREA", token) == 0){
double rel_sa_x, rel_sa_y, rel_sa_rl, rel_sa_cl;
int aid = 1;
- char maskname[150];
+ char maskname[GNAME_MAX];
do{
rel_sa_x = atof(strtok(NULL, "|"));
rel_sa_y = atof(strtok(NULL, "|"));
@@ -413,7 +413,7 @@
else if (strcmp("MASKEDOVERLAYAREA", token) == 0){
double sa_n, sa_s, sa_w, sa_e;
int aid = 1;
- char maskname[150];
+ char maskname[GNAME_MAX];
msg m;
do {
strcpy(maskname, strtok(NULL,"|"));
Modified: grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/ipc.h
===================================================================
--- grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/ipc.h 2008-05-28 13:19:50 UTC (rev 31546)
+++ grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/ipc.h 2008-05-28 13:31:03 UTC (rev 31547)
@@ -53,7 +53,7 @@
int y;
int rl;
int cl;
- char mask[150];
+ char mask[GNAME_MAX];
} fields_maskedarea ;
/**
Modified: grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/main.c
===================================================================
--- grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/main.c 2008-05-28 13:19:50 UTC (rev 31546)
+++ grass/branches/releasebranch_6_3/raster/r.li/r.li.daemon/main.c 2008-05-28 13:31:03 UTC (rev 31547)
@@ -63,7 +63,7 @@
CELL *buf, *sup;
int count, i,j, connected=0, complete_line=1;
double area;
- char *mapset, c[150];
+ char *mapset, c[GPATH_MAX];
struct Cell_head hd;
CELL complete_value;
More information about the grass-commit
mailing list