[packages/swig] - adjusted php-freearg patch to emit arg_count checks only for optional arguments, not e.g. output

qboosh qboosh at pld-linux.org
Sun May 11 06:21:15 CEST 2014


commit ece3c07870c90a5912faf96fe6643a0d10ac9575
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun May 11 06:23:45 2014 +0200

    - adjusted php-freearg patch to emit arg_count checks only for optional arguments,
      not e.g. outputs; fixes compilation errors regarding arg_count
    - release 2

 swig-php-freearg.patch | 4 ++--
 swig.spec              | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/swig.spec b/swig.spec
index 864a623..1cada5b 100644
--- a/swig.spec
+++ b/swig.spec
@@ -13,7 +13,7 @@ Summary(pl.UTF-8):	Generator interfejsów do Perla, Tcl-a, Guile'a i Pythona
 Summary(pt_BR.UTF-8):	Gerador de Interfaces e "Wrappers" Simplificado (SWIG)
 Name:		swig
 Version:	2.0.12
-Release:	1
+Release:	2
 License:	GPL v3+ (utility), free (library)
 Group:		Development/Languages
 Source0:	http://downloads.sourceforge.net/swig/%{name}-%{version}.tar.gz
diff --git a/swig-php-freearg.patch b/swig-php-freearg.patch
index cc3b72d..cdc8624 100644
--- a/swig-php-freearg.patch
+++ b/swig-php-freearg.patch
@@ -4,7 +4,7 @@
  
      /* Insert cleanup code */
      for (i = 0, p = l; p; i++) {
-+      if(i>= (num_required))
++      if((i >= num_required) && (i < num_required+numopt))
 +	Printf(cleanup,"\tif(arg_count > %d) {\n", i);
        if ((tm = Getattr(p, "tmap:freearg"))) {
  	Replaceall(tm, "$source", Getattr(p, "lname"));
@@ -13,7 +13,7 @@
        } else {
  	p = nextSibling(p);
        }
-+      if (i >= num_required)
++      if ((i >= num_required) && (i < num_required+numopt))
 +        Printf(cleanup,"}\n");
      }
  
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/swig.git/commitdiff/ece3c07870c90a5912faf96fe6643a0d10ac9575



More information about the pld-cvs-commit mailing list