[gdal-dev] Is it possible to "hide" some ERROR messages?

Tom Kazimiers 2voodoo at gmx.de
Fri Oct 24 07:35:51 EDT 2008


Hi Daniele,

were to you get those error message? Since GDAL is a library  it
shouldn't come up with thing like this - at least not errors which are
shown to the user automatically (like message boxes or std::out prints
(I guess). So if your application gets no dataset for a file it will get
NULL returned, you can then do with this information what you want -
either inform the user about it or not.

Bye,
Tom

Daniele Romagnoli schrieb:
> Hi list,
> Is it somehow possible to customize/hide some GDAL error messages?
> I know error messages are really useful to fix/understand problems.
> Anyway, let me expose my use case:
>
> I simply need to check if I can obtain a Dataset for a file and return
> a boolean.
> If I get a Dataset, great! Otherwise... no problem. :)
> The user won't see messages like this "ERROR 4: `c:\mydataformat.frmt'
> not recognised as a supported file format" (although by this way he
> will never know why no Dataset has ben acquired).
>
> Is there some setConfigOption("xxx",) to hide (some) error messages?
>
> Thank you.
> Regards,
>
> Daniele
>
>
> -- 
> -------------------------------------------------------
> Eng. Daniele Romagnoli
> Software Engineer
>
> GeoSolutions S.A.S.
> Via Carignoni 51
> 55041 Camaiore (LU)
> Italy
>
> phone: +39 0584983027
> fax:     +39 0584983027
> mob:   +39 328 0559267
>
>
> http://www.geo-solutions.it
>
> -------------------------------------------------------
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev



More information about the gdal-dev mailing list