Fixup fromcvs/togit conversion
[minix-pkgsrc.git] / wm / afterstep / patches / patch-libAfterImage_import.c
blobe5b031111715eb1ab77df8866f7848bf0e0d9679
1 $NetBSD$
2 * fix for png-1.5
3 --- libAfterImage/import.c.orig 2010-09-23 20:57:57.000000000 +0000
4 +++ libAfterImage/import.c
5 @@ -1251,7 +1251,7 @@ png2ASImage_int( void *data, png_rw_ptr
6 * the normal method of doing things with libpng). REQUIRED unless you
7 * set up your own error handlers in the png_create_read_struct() earlier.
8 */
9 - if ( !setjmp (png_ptr->jmpbuf))
10 + if ( !setjmp (png_jmpbuf(png_ptr)))
12 ASFlagType rgb_flags = ASStorage_RLEDiffCompress|ASStorage_32Bit ;
14 @@ -1447,8 +1447,8 @@ png2ASImage_int( void *data, png_rw_ptr
16 /* clean up after the read, and free any memory allocated - REQUIRED */
17 png_destroy_read_struct (&png_ptr, &info_ptr, (png_infopp) NULL);
18 - if (info_ptr)
19 - free (info_ptr);
20 +// if (info_ptr)
21 +// free (info_ptr);
24 #if defined(LOCAL_DEBUG) && !defined(NO_DEBUG_OUTPUT)
25 @@ -1468,7 +1468,7 @@ typedef struct ASImPNGReadBuffer
27 static void asim_png_read_data(png_structp png_ptr, png_bytep data, png_size_t length)
29 - ASImPNGReadBuffer *buf = (ASImPNGReadBuffer *)png_ptr->io_ptr;
30 + ASImPNGReadBuffer *buf = (ASImPNGReadBuffer *)png_get_io_ptr(png_ptr);
31 memcpy(data, buf->buffer, length);
32 buf->buffer += length;