Index: /trunk/ippScripts/scripts/detrend_resid.pl
===================================================================
--- /trunk/ippScripts/scripts/detrend_resid.pl	(revision 10320)
+++ /trunk/ippScripts/scripts/detrend_resid.pl	(revision 10321)
@@ -123,7 +123,4 @@
 
 # Add the processed file to the database
-# XXX I think this has the names "bg_stdev" and "bg_mean_stdev" exchanged
-#     bg_stdev : standard deviation of the background
-#     bg_mean_stdev : standard deviation of the background means
 $outputName = File::Spec->abs2rel ($outputName, $ipprc->workdir() );
 $bin1Name = File::Spec->abs2rel( $bin1Name, $ipprc->workdir() );
@@ -135,7 +132,6 @@
     $command .= " -bg " . $stats->bg_mean();
 
-    # XXX note bg_stdev <--> bg_mean_stdev
-    if (defined($stats->bg_stdev())) {
-	$command .= " -bg_mean_stdev " . $stats->bg_stdev();
+    if (defined($stats->bg_mean_stdev())) {
+	$command .= " -bg_mean_stdev " . $stats->bg_mean_stdev();
     } else {
 	# May be undefined if there is only a single imfile
@@ -143,6 +139,5 @@
     }
 
-    # XXX note bg_stdev <--> bg_mean_stdev
-    $command .= " -bg_stdev " . $stats->bg_mean_stdev();
+    $command .= " -bg_stdev " . $stats->bg_stdev();
 
     my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
