On Wed, Jul 27, 2011 at 10:52:57AM +0200, Bruno Friedmann wrote:
Hi, I'm building a mapserver5 version in
With the latest version which contain security bug fixes I'm now getting a build failed
I: Program returns random data in a function E: mapserver5 no-return-in-nonvoid-function mapogr.cpp:3500
Here the function /************************************************************************/ /* msOGREscapeSQLParam */ /************************************************************************/ char *msOGREscapeSQLParam(layerObj *layer, const char *pszString) { char* pszEscapedStr =NULL; #ifdef USE_OGR if(layer && pszString && strlen(pszString) > 0) { char* pszEscapedOGRStr = CPLEscapeString(pszString, strlen(pszString), CPLES_SQL ); pszEscapedStr = strdup(pszEscapedOGRStr); CPLFree(pszEscapedOGRStr); return pszEscapedStr; }
<<<<<<<<< Here should be a return too. Perhaps a return NULL;? z
#else /* ------------------------------------------------------------------ * OGR Support not included... * ------------------------------------------------------------------ */
msSetError(MS_MISCERR, "OGR support is not available.", "msOGREscapeSQLParam()"); return NULL;
#endif /* USE_OGR */ }
How can I ride off of the error ? return pszString (string untouched ?)
sorry my c/c++ knowledge are very limited.
See insert above. Ciao, Marcus -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-packaging+help@opensuse.org