Imported from libpng-1.2.0beta2.tar
diff --git a/pngwio.c b/pngwio.c
index febf217..9ada920 100644
--- a/pngwio.c
+++ b/pngwio.c
@@ -1,7 +1,7 @@
 
 /* pngwio.c - functions for data output
  *
- * libpng 1.2.0beta1 - May 6, 2001
+ * libpng 1.2.0beta2 - May 7, 2001
  * For conditions of distribution and use, see copyright notice in png.h
  * Copyright (c) 1998-2001 Glenn Randers-Pehrson
  * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
@@ -17,6 +17,7 @@
 
 #define PNG_INTERNAL
 #include "png.h"
+#ifdef PNG_WRITE_SUPPORTED
 
 /* Write the data to whatever output you are using.  The default routine
    writes to a file pointer.  Note that this routine sometimes gets called
@@ -224,3 +225,4 @@
 }
 #   endif
 #   endif
+#endif /* PNG_WRITE_SUPPORTED */