[gdal-dev] [mapserver-dev] New env. var. to make it easier to test/debug web services

Even Rouault even.rouault at spatialys.com
Thu Oct 2 13:09:50 PDT 2014


Le jeudi 02 octobre 2014 21:41:20, Jeff McKenna a écrit :
> On 2014-10-02 4:24 PM, Even Rouault wrote:
> > Le jeudi 02 octobre 2014 21:01:58, Even Rouault a écrit :
> >> Le jeudi 02 octobre 2014 20:57:46, Lime, Steve D (MNIT) a écrit :
> >>> How about making -nh set the environment variable programatically and
> >>> losing the sendheaders checks?
> >> 
> >> Yes, that's a possibility. Although I think -nh could just call a
> >> function to disable the boolean in msio instead of messing with
> >> environmenet variables.
> > 
> > I've just implemented that. So no more env. variable trick. Just the
> > standard -nh mechanism.
> > 
> > Would be cool to have a "mapserv --help" mode to display available
> > options, wouldn't it ?
> 
> Would be super cool!  It would list the -nh and -v options (I don't know
> of other options).  

With my latest commit, and default configuration :

$ mapserv --help
Usage: mapserv [--help] [-v] [-nh] [QUERY_STRING=value]

Options :
  -h, --help              Display this help message
  -v                      Display version and exit.
  -nh                     Suppress HTTP headers in CGI mode.
  QUERY_STRING=value      Set the QUERY_STRING in GET request mode.

When compiled with -DMS_ENABLE_CGI_CL_DEBUG_ARGS

$ mapserv --help
Usage: mapserv [--help] [-v] [-nh] [QUERY_STRING=value]
               [-tmpbase dirname] [-t mapfilename] [MS_ERRORFILE=value] [MS_DEBUGLEVEL=value]

Options :
  -h, --help              Display this help message
  -v                      Display version and exit.
  -nh                     Suppress HTTP headers in CGI mode.
  QUERY_STRING=value      Set the QUERY_STRING in GET request mode.
  -tmpbase dirname        Define a forced temporary directory.
  -t mapfilename          Display the tokens of the mapfile after parsing.
  MS_ERRORFILE=filename   Set error file.
  MS_DEBUGLEVEL=value     Set debug level.


> The default message is, not fully correct:
> 
>    "This script can only be used to decode form results and should be
> initiated as a CGI process via a httpd server"

Any suggestion ?

> 
> 
> -jeff
> 
> 
> 
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com


More information about the gdal-dev mailing list