pdf_util.h

Mon, 14 Dec 2009 16:18:21 +0000

author
Philip Pemberton <philpem@philpem.me.uk>
date
Mon, 14 Dec 2009 16:18:21 +0000
changeset 172
2fae6df568f6
parent 125
e2ef1c2f9eca
permissions
-rw-r--r--

remove erroneous 0.33-philpem1 tag

eric@62 1 /*
eric@125 2 * tumble: build a PDF file from image files
eric@62 3 *
eric@62 4 * PDF routines
eric@125 5 * $Id: pdf_util.h,v 1.6 2003/03/13 00:57:05 eric Exp $
eric@62 6 * Copyright 2001, 2002, 2003 Eric Smith <eric@brouhaha.com>
eric@62 7 *
eric@62 8 * This program is free software; you can redistribute it and/or modify
eric@62 9 * it under the terms of the GNU General Public License version 2 as
eric@62 10 * published by the Free Software Foundation. Note that permission is
eric@62 11 * not granted to redistribute this program under the terms of any
eric@62 12 * other version of the General Public License.
eric@62 13 *
eric@62 14 * This program is distributed in the hope that it will be useful,
eric@62 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
eric@62 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
eric@62 17 * GNU General Public License for more details.
eric@62 18 *
eric@62 19 * You should have received a copy of the GNU General Public License
eric@62 20 * along with this program; if not, write to the Free Software
eric@62 21 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 USA
eric@62 22 */
eric@62 23
eric@62 24
eric@74 25 #include <assert.h>
eric@74 26
eric@74 27
eric@81 28 void pdf_fatal (char *fmt, ...) __attribute__ ((noreturn));
eric@59 29
eric@67 30 void *pdf_calloc (size_t nmemb, size_t size);
eric@59 31
eric@59 32 char *pdf_strdup (char *s);
eric@59 33
eric@74 34 #if 1
eric@74 35 #define pdf_assert(cond) assert(cond)
eric@74 36 #else
eric@59 37 #define pdf_assert(cond) do \
eric@59 38 { \
eric@59 39 if (! (cond)) \
eric@59 40 pdf_fatal ("assert at %s(%d)\n", __FILE__, __LINE__); \
eric@59 41 } while (0)
eric@74 42 #endif