Opened 15 years ago

Closed 9 years ago

#3195 closed defect (wontfix)

grib1 driver should print warnings to stderr

Reported by: jluis Owned by: warmerdam
Priority: low Milestone:
Component: GDAL_Raster Version: svn-trunk
Severity: normal Keywords: grib
Cc:

Description

Hi,

Not sure if this should be classified as a bug or an enhancement. The grib1 driver prints the warnings to stdout but it should do it to stderr. This poses a problem with GMT when the output is redirected to a pstscript file. In cases when warnings are issued, like it happened recently with messages like "Warning! : Can't figure out time unit of 4" the postscript file is corrupted with the presence of those "warnings". The solution is to simply print the warnings to stderr.

Joaquim Luis

Change History (2)

comment:1 by warmerdam, 14 years ago

Component: defaultGDAL_Raster
Keywords: grib added
Milestone: 1.6.4
Priority: normallow

I have confirmed that the degrib library has many plain printf's apparently used for warnings and errors. The following query may find most of them.

% pwd                                                        /wrk/home/warmerda/tree-gdal/trunk/gdal/frmts/grib/degrib18
% grep printf */*.c | grep -v -i sprintf | grep -v fprintf | less

Generally I hesitate to make changes in the degrib code because I know it will all be lost again when the code is next replaced from upstream. As such, I've been treating this as low priority.

comment:2 by Jukka Rahkonen, 9 years ago

Resolution: wontfix
Status: newclosed

If developers say that they treat some fix as low priority it tends to mean the same as won't fix.

Note: See TracTickets for help on using tickets.