Index: trunk/psLib/src/fits/psFitsImage.c
===================================================================
--- trunk/psLib/src/fits/psFitsImage.c	(revision 16934)
+++ trunk/psLib/src/fits/psFitsImage.c	(revision 17447)
@@ -7,6 +7,6 @@
  *  @author Robert DeSonia, MHPCC
  *
- *  @version $Revision: 1.27 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2008-03-11 19:57:41 $
+ *  @version $Revision: 1.28 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2008-04-17 23:43:02 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -253,9 +253,9 @@
                                           )
 {
-    assert(bscale);
-    assert(bzero);
-    assert(floatType);
-    assert(fits);
-    assert(image);
+    psAssert(bscale, "impossible");
+    psAssert(bzero, "impossible");
+    psAssert(floatType, "impossible");
+    psAssert(fits, "impossible");
+    psAssert(image, "impossible");
 
     *bscale = 1.0;
@@ -358,10 +358,10 @@
 {
     // n.b., this assumes contiguous image buffer
-    assert(output);
-    assert(fits);
-    assert(info);
-    assert(output->numCols == info->lastPixel[0] - info->firstPixel[0] + 1);
-    assert(output->numRows == info->lastPixel[1] - info->firstPixel[1] + 1); // Right size
-    assert(!output->parent);            // No parents means the buffer is contiguous
+    psAssert(output, "impossible");
+    psAssert(fits, "impossible");
+    psAssert(info, "impossible");
+    psAssert(output->numCols == info->lastPixel[0] - info->firstPixel[0] + 1, "impossible");
+    psAssert(output->numRows == info->lastPixel[1] - info->firstPixel[1] + 1, "impossible"); // Right size
+    psAssert(!output->parent, "impossible");            // No parents means the buffer is contiguous
 
     int anynull = 0;                    // Are there any NULLs in the data?
@@ -516,10 +516,10 @@
     if (cfitsioBzero != 0.0) {
         // p_psFitsTypeToCfitsio and imageToDiskRepresentation must not clash!
-        assert(bzero == 0.0 && bscale == 1.0);
+        psAssert(bzero == 0.0 && bscale == 1.0, "impossible");
         bscale = 1.0;
         bzero = cfitsioBzero;
     }
     psFitsOptions *options = fits->options; // FITS I/O options
-    assert(!options || bitPix == options->bitpix || options->bitpix == 0);
+    psAssert(!options || bitPix == options->bitpix || options->bitpix == 0, "impossible");
 
     int naxis = 3;                      // Number of axes
@@ -647,10 +647,10 @@
     if (cfitsioBzero != 0.0) {
         // p_psFitsTypeToCfitsio and imageToDiskRepresentation must not clash!
-        assert(bzero == 0.0 && bscale == 1.0);
+        psAssert(bzero == 0.0 && bscale == 1.0, "impossible");
         bscale = 1.0;
         bzero = cfitsioBzero;
     }
     psFitsOptions *options = fits->options; // FITS I/O options
-    assert(!options || bitPix == options->bitpix || options->bitpix == 0);
+    psAssert(!options || bitPix == options->bitpix || options->bitpix == 0, "impossible");
 
     //check to see if the HDU has the same datatype
