--- xnecview-1.36/xwin.c.orig	2014-11-28 14:59:50.347612817 +0100
+++ xnecview-1.36/xwin.c	2014-11-28 14:59:14.664660161 +0100
@@ -278,7 +277,7 @@ int write_png(int which,const char *file
       fclose(f);
       return 1;
    }
-   if (setjmp(pp->jmpbuf)) {
+   if (setjmp(png_jmpbuf(pp))) {
       png_destroy_write_struct(&pp,&ip);
       fclose(f);
       gdk_image_destroy(image);
