cvs: /php4/ext/fdf fdf.c config.m4

From: Date: Wed, 06 Oct 1999 05:23:59 +0000
Subject: cvs: /php4/ext/fdf fdf.c config.m4
Groups: php.version4 
Request: Send a blank email to php-version4+get-5217@lists.php.net to get a copy of this message
steinm Wed Oct 6 01:23:59 1999 EDT Modified files: /php4/ext/fdf fdf.c config.m4 Log: - fix to work with new version of FdfTk Index: php4/ext/fdf/fdf.c diff -u php4/ext/fdf/fdf.c:1.8 php4/ext/fdf/fdf.c:1.9 --- php4/ext/fdf/fdf.c:1.8 Fri Aug 6 02:52:06 1999 +++ php4/ext/fdf/fdf.c Wed Oct 6 01:23:28 1999 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: fdf.c,v 1.8 1999/08/06 06:52:06 steinm Exp $ */ +/* $Id: fdf.c,v 1.9 1999/10/06 05:23:28 steinm Exp $ */ /* FdfTk lib 2.0 is a Complete C/C++ FDF Toolkit available from http://beta1.adobe.com/ada/acrosdk/forms.html. */ @@ -217,6 +217,13 @@ err = FDFGetValue(fdf, arg2->value.str.val, NULL, 0, &nr); if(err != FDFErcOK) printf("Aiii, error\n"); + /* In the inofficial version of FdfTK 4.0 (as FDFGetVersion says. The + library has a name with version 3.0, don't know what adobe has in + mind) the number of bytes of the value doesn't include the trailing + '\0'. This was not the case in 2.0 + */ + if(strcmp(FDFGetVersion(), "2.0")) + nr++; buffer = emalloc(nr); err = FDFGetValue(fdf, arg2->value.str.val, buffer, nr, &nr); if(err != FDFErcOK) Index: php4/ext/fdf/config.m4 diff -u php4/ext/fdf/config.m4:1.2 php4/ext/fdf/config.m4:1.3 --- php4/ext/fdf/config.m4:1.2 Wed Sep 22 01:27:55 1999 +++ php4/ext/fdf/config.m4 Wed Oct 6 01:23:28 1999 @@ -1,4 +1,4 @@ -dnl $Id: config.m4,v 1.2 1999/09/22 05:27:55 steinm Exp $ +dnl $Id: config.m4,v 1.3 1999/10/06 05:23:28 steinm Exp $ AC_MSG_CHECKING(whether to include fdftk support) AC_ARG_WITH(fdftk, @@ -18,7 +18,7 @@ ],[AC_MSG_ERROR(fdftk module requires fdftk 2.0)]) ;; *) - test -f $withval/include/Fdftk.h && FDFLIB_INCLUDE="-I$withval/include" + test -f $withval/include/FdfTk.h && FDFLIB_INCLUDE="-I$withval/include" if test -n "$FDFLIB_INCLUDE" ; then AC_MSG_RESULT(yes) PHP_EXTENSION(fdf)

« previous php.version4 (#5217) next »