Skip to content

Commit

Permalink
Merge branch 'branch-6-0' of https://github.com/mapserver/mapserver i…
Browse files Browse the repository at this point in the history
…nto branch-6-0
  • Loading branch information
constantinius committed Jul 4, 2012
2 parents eaddf28 + 917ce92 commit 95d959e
Show file tree
Hide file tree
Showing 6 changed files with 45 additions and 12 deletions.
4 changes: 4 additions & 0 deletions HISTORY.TXT
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ For a complete change history, please see the Git log comments.
Current Version (future 6.0.4, GIT branch-6-0):
-----------------------------------------------

- Fixed PHP MapScript support for PHP 5.4 (#4309)

- Fix msOGREscapeSQLParam could return random data (#4335)

- Fixed locations of supported and native formats in Capabilities and CoverageDescriptions for WCS 2.0 (#4003)

- Made format parameter for WCS 2.0 GetCoverage requests optional (#4003)
Expand Down
15 changes: 15 additions & 0 deletions MIGRATION_GUIDE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,21 @@ are evaluated in OGC WCS services. Previous versions used "wms_*"
prefixed entries as fallback which is dropped in version 6.0 in favor of
forcing explicit decisions.

-------------------------------------------------------
Mapfile Changes - OGC requests - DUMP parameter removed
-------------------------------------------------------

The DUMP LAYER parameter has been removed. To enable output of
geometries in WMS getfeatureinfo requests - GML
(INFO_FORMAT=application/vnd.ogc.gml), LAYER METADATA is used
instead::

METADATA
gml_geometries "geom"
gml_geom_type "polygon"
...
END

--------------------------------------------------------
Mapfile Changes - Ability to escape single/double quotes
--------------------------------------------------------
Expand Down
7 changes: 3 additions & 4 deletions mapogr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3710,17 +3710,16 @@ char *msOGREscapeSQLParam(layerObj *layer, const char *pszString)
CPLES_SQL );
pszEscapedStr = msStrdup(pszEscapedOGRStr);
CPLFree(pszEscapedOGRStr);
return pszEscapedStr;
}
return pszEscapedStr;
#else
/* ------------------------------------------------------------------
* OGR Support not included...
* ------------------------------------------------------------------ */

msSetError(MS_MISCERR, "OGR support is not available.",
"msOGREscapeSQLParam()");
return NULL;

return NULL;
#endif /* USE_OGR */
}

Expand Down Expand Up @@ -3753,8 +3752,8 @@ char *msOGREscapePropertyName(layerObj *layer, const char *pszString)

msSetError(MS_MISCERR, "OGR support is not available.",
"msOGREscapePropertyName()");
return NULL;

return NULL;
#endif /* USE_OGR */
}
/************************************************************************/
Expand Down
15 changes: 10 additions & 5 deletions mapscript/php/image.c
Original file line number Diff line number Diff line change
Expand Up @@ -303,12 +303,17 @@ PHP_METHOD(imageObj, saveImage)
/* no filename - read stdout */

/* if there is no output buffer active, set the header */
if (OG(ob_nesting_level)<=0)
{
php_header(TSRMLS_C);
}
//handle changes in PHP 5.4.x
#if PHP_VERSION_ID < 50399
if (OG(ob_nesting_level)<=0) {
php_header(TSRMLS_C);
}
#else
if (php_output_get_level(TSRMLS_C)<=0) {
php_header(TSRMLS_C);
}
#endif


if (MS_RENDERER_PLUGIN(php_image->image->format))
{
iptr = (void *)msSaveImageBuffer(php_image->image, &size, php_image->image->format);
Expand Down
2 changes: 1 addition & 1 deletion mapscript/php/php_mapscript.c
Original file line number Diff line number Diff line change
Expand Up @@ -899,7 +899,7 @@ PHP_FUNCTION(ms_tokenizeMap)

}

function_entry mapscript_functions[] = {
zend_function_entry mapscript_functions[] = {
PHP_FE(ms_GetVersion, NULL)
PHP_FE(ms_GetVersionInt, NULL)
PHP_FE(ms_newLineObj, NULL)
Expand Down
14 changes: 12 additions & 2 deletions mapscript/php/php_mapscript_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,12 @@ zend_object_value mapscript_object_new(zend_object *zobj,
zobj->ce = ce;
ALLOC_HASHTABLE(zobj->properties);
zend_hash_init(zobj->properties, 0, NULL, ZVAL_PTR_DTOR, 0);
zend_hash_copy(zobj->properties, &ce->default_properties, (copy_ctor_func_t) zval_add_ref,(void *) &temp, sizeof(zval *));
//handle changes in PHP 5.4.x
#if PHP_VERSION_ID < 50399
zend_hash_copy(zobj->properties, &ce->default_properties, (copy_ctor_func_t) zval_add_ref,(void *) &temp, sizeof(zval *));
#else
object_properties_init(zobj, ce);
#endif
retval.handle = zend_objects_store_put(zobj, NULL, (zend_objects_free_object_storage_t)zend_objects_free_object, NULL TSRMLS_CC);
retval.handlers = &mapscript_std_object_handlers;
return retval;
Expand All @@ -59,7 +64,12 @@ zend_object_value mapscript_object_new_ex(zend_object *zobj,
zobj->ce = ce;
ALLOC_HASHTABLE(zobj->properties);
zend_hash_init(zobj->properties, 0, NULL, ZVAL_PTR_DTOR, 0);
zend_hash_copy(zobj->properties, &ce->default_properties, (copy_ctor_func_t) zval_add_ref,(void *) &temp, sizeof(zval *));
//handle changes in PHP 5.4.x
#if PHP_VERSION_ID < 50399
zend_hash_copy(zobj->properties, &ce->default_properties, (copy_ctor_func_t) zval_add_ref,(void *) &temp, sizeof(zval *));
#else
object_properties_init(zobj, ce);
#endif
retval.handle = zend_objects_store_put(zobj, NULL, (zend_objects_free_object_storage_t)zend_objects_free_object, NULL TSRMLS_CC);
retval.handlers = object_handlers;
return retval;
Expand Down

0 comments on commit 95d959e

Please sign in to comment.