[libvirt] [libvirt-php PATCH 1/1] Fix: mutlithreading compilation: set_error needs 2 params

Michal Novotny minovotn at redhat.com
Mon Apr 8 16:25:03 UTC 2013


On 02/01/2013 03:25 PM, stefan.kuhn at foss-group.ch wrote:
> ---
>  src/libvirt-php.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/src/libvirt-php.c b/src/libvirt-php.c
> index 7e7710c..0b8345a 100644
> --- a/src/libvirt-php.c
> +++ b/src/libvirt-php.c
> @@ -1615,7 +1615,7 @@ PHP_FUNCTION(libvirt_node_get_cpu_stats)
>  #else
>  PHP_FUNCTION(libvirt_node_get_cpu_stats)
>  {
> -	set_error("Function is not supported by libvirt, support has been added in libvirt 0.9.3");
> +	set_error("Function is not supported by libvirt, support has been added in libvirt 0.9.3" TSRMLS_CC);
>  	RETURN_FALSE;
>  }
>  #endif
> @@ -1718,7 +1718,7 @@ PHP_FUNCTION(libvirt_node_get_cpu_stats_for_each_cpu)
>  #else
>  PHP_FUNCTION(libvirt_node_get_cpu_stats_for_each_cpu)
>  {
> -	set_error("Function is not supported by libvirt, support has been added in libvirt 0.9.3");
> +	set_error("Function is not supported by libvirt, support has been added in libvirt 0.9.3" TSRMLS_CC);
>  	RETURN_FALSE;
>  }
>  #endif
> @@ -1775,7 +1775,7 @@ PHP_FUNCTION(libvirt_node_get_mem_stats)
>  #else
>  PHP_FUNCTION(libvirt_node_get_mem_stats)
>  {
> -	set_error("Function is not supported by libvirt, support has been added in libvirt 0.9.3");
> +	set_error("Function is not supported by libvirt, support has been added in libvirt 0.9.3" TSRMLS_CC);
>  	RETURN_FALSE;
>  }
>  #endif
> @@ -3168,7 +3168,7 @@ PHP_FUNCTION(libvirt_domain_get_screenshot_api)
>  #else
>  PHP_FUNCTION(libvirt_domain_get_screenshot_api)
>  {
> -	set_error("Function is not supported by libvirt, you need at least libvirt 0.9.2 to support this function");
> +	set_error("Function is not supported by libvirt, you need at least libvirt 0.9.2 to support this function" TSRMLS_CC);
>  	RETURN_FALSE;
>  }
>  #endif
> @@ -5453,13 +5453,13 @@ PHP_FUNCTION(libvirt_domain_migrate)
>  	GET_DOMAIN_FROM_ARGS("rrl|sl",&zdomain,&zdconn,&flags,&dname,&dname_len,&bandwidth);
>  
>  	if ((domain->domain == NULL) || (domain->conn->conn == NULL)) {
> -		set_error("Domain object is not valid");
> +		set_error("Domain object is not valid" TSRMLS_CC);
>  		RETURN_FALSE;
>  	}
>  
>  	ZEND_FETCH_RESOURCE(dconn, php_libvirt_connection*, &zdconn, -1, PHP_LIBVIRT_CONNECTION_RES_NAME, le_libvirt_connection);
>  	if ((dconn==NULL) || (dconn->conn==NULL)) {
> -		set_error("Destination connection object is not valid");
> +		set_error("Destination connection object is not valid" TSRMLS_CC);
>  		RETURN_FALSE;
>  	}
>  
Thanks, pushed!

Michal

-- 
Michal Novotny <minovotn at redhat.com>, RHCE, Red Hat
Virtualization | libvirt-php bindings | php-virt-control.org




More information about the libvir-list mailing list