cvs: /php4/ext/pdf pdf.c

From: Date: Tue, 07 Mar 2000 20:51:44 +0000
Subject: cvs: /php4/ext/pdf pdf.c
Groups: php.version4 
Request: Send a blank email to php-version4+get-11716@lists.php.net to get a copy of this message
steinm Tue Mar 7 12:51:44 2000 EDT Modified files: /php4/ext/pdf pdf.c Log: - support for pdflib 3.0 Index: php4/ext/pdf/pdf.c diff -u php4/ext/pdf/pdf.c:1.28 php4/ext/pdf/pdf.c:1.29 --- php4/ext/pdf/pdf.c:1.28 Tue Mar 7 09:29:24 2000 +++ php4/ext/pdf/pdf.c Tue Mar 7 12:51:14 2000 @@ -27,7 +27,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: pdf.c,v 1.28 2000/03/07 17:29:24 steinm Exp $ */ +/* $Id: pdf.c,v 1.29 2000/03/07 20:51:14 steinm Exp $ */ /* pdflib 2.01 is subject to the ALADDIN FREE PUBLIC LICENSE. Copyright (C) 1997 Thomas Merz. */ @@ -192,7 +192,6 @@ if(outline) efree(outline); } -#if PDFLIB_MAJORVERSION > 1 & PDFLIB_MINORVERSION > 0 static void custom_errorhandler(PDF *p, int type, const char*shortmsg) { switch (type){ case PDF_NonfatalError: @@ -226,7 +225,6 @@ static void pdf_efree(PDF *p, void *mem) { return(efree(mem)); } -#endif #if PDFLIB_MAJORVERSION >= 3 | (PDFLIB_MAJORVERSION >= 2 & PDFLIB_MINORVERSION >= 10) static size_t pdf_flushwrite(PDF *p, void *data, size_t size){ @@ -254,7 +252,7 @@ php_printf("Support for in memory pdf creation."); #endif -#if PDFLIB_MINORVERSION > 0 +#if PDFLIB_MAJORVERSION >= 3 | PDFLIB_MINORVERSION > 0 php_printf("The function pdf_put_image() and pdf_execute_image() are <B>not</B> available"); #else php_printf("The function pdf_put_image() and pdf_execute_image() are available"); @@ -420,7 +418,7 @@ int argc; PDF_TLS_VARS; -#if PDFLIB_MAJORVERSION >= 2 & PDFLIB_MINORVERSION >= 10 +#if PDFLIB_MAJORVERSION >= 3 | (PDFLIB_MAJORVERSION >= 2 & PDFLIB_MINORVERSION >= 10) argc = ARG_COUNT(ht); if(argc > 1) WRONG_PARAM_COUNT; @@ -440,11 +438,7 @@ /* XXX should do anzend_list_addref for <fp> here! */ #endif -#if PDFLIB_MAJORVERSION > 1 & PDFLIB_MINORVERSION > 0 pdf = PDF_new2(custom_errorhandler, pdf_emalloc, pdf_realloc, pdf_efree, NULL); -#else - pdf = PDF_new(); -#endif #if PDFLIB_MAJORVERSION >= 2 & PDFLIB_MINORVERSION >= 10 & defined PDF_OPEN_MEM_SUPPORTED if(fp) {

« previous php.version4 (#11716) next »