Opened 15 years ago
Closed 15 years ago
#3182 closed defect (fixed)
ows_encoding ignored by wfs 1.1
Reported by: | mko | Owned by: | aboudreault |
---|---|---|---|
Priority: | high | Milestone: | 5.4.3 release |
Component: | MapServer C Library | Version: | 5.4 |
Severity: | major | Keywords: | encoding wfs11 |
Cc: | mko, aboudreault |
Description
In WFS 1.1 implementation there's ISO-8859-1 hardcoded which might make clients stop reading service capabilities.
xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1);
Change History (7)
comment:1 by , 15 years ago
Cc: | added |
---|
follow-up: 3 comment:2 by , 15 years ago
I suppose those calls should use the "*_encoding" metadata as well?
comment:3 by , 15 years ago
comment:4 by , 15 years ago
Owner: | changed from | to
---|
comment:5 by , 15 years ago
Actually, I wonder if we should do this everywhere we define ISO-8859-1 as default:
[devgeo:/home/tkralidi/foss4g/mapserver/svn/trunk/mapserver]$ grep "ISO-8859-1" *.[ch] mapcontext.c: "ISO-8859-1"); mapgml.c: /* "wms_encoding", and if not found then use "ISO-8859-1" as default. */ mapgml.c: msOWSPrintEncodeMetadata(stream, &(map->web.metadata), namespaces, "encoding", OWS_NOERR, "<?xml version=\"1.0\" encoding=\"%s\"?>\n\n", "ISO-8859-1"); mapogcsos.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapogcsos.c: "ISO-8859-1"); mapogcsos.c: /*xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1);*/ mapogcsos.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapogcsos.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapwcs11.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapwcs11.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapwcs11.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapwcs.c: msOWSPrintEncodeMetadata(stdout, &(map->web.metadata), NULL, "wcs_encoding", OWS_NOERR, "<?xml version='1.0' encoding=\"%s\" ?>\n", "ISO-8859-1"); mapwcs.c: msOWSPrintEncodeMetadata(stdout, &(map->web.metadata), NULL, "wcs_encoding", OWS_NOERR, "<?xml version='1.0' encoding=\"%s\" standalone=\"no\" ?>\n", "ISO-8859-1"); mapwcs.c: msOWSPrintEncodeMetadata(stdout, &(map->web.metadata), NULL, "wcs_encoding", OWS_NOERR, "<?xml version='1.0' encoding=\"%s\" ?>\n", "ISO-8859-1"); mapwfs11.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapwfs11.c: xmlDocDumpFormatMemoryEnc(psDoc, &buffer, &size, "ISO-8859-1", 1); mapwfs.c: "<?xml version='1.0' encoding=\"%s\" ?>\n", "ISO-8859-1"); mapwfs.c: "ISO-8859-1"); mapwfs.c: "ISO-8859-1"); mapwfs.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1"); mapwms.c: "ISO-8859-1");
comment:6 by , 15 years ago
All msOWSPrintEncodeMetadata() calls are already Ok. They already check if the metadata is present, else use the default.
comment:7 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
The proper encoding will now be set in the xml tag for all requests. Note that if you do a SOS request, it will look for the "sos_encoding" metadata, if not found, the "ows_encoding" metadata, else "ISO-8859-1". Same thing for wms/wfs, etc.
Fixed and committed in r9498.
FYI this happens a few places in the codebase:
FYI related to #2583.