Index: /branches/eam_branches/20091201/Ohana/src/libautocode/generate
===================================================================
--- /branches/eam_branches/20091201/Ohana/src/libautocode/generate	(revision 26711)
+++ /branches/eam_branches/20091201/Ohana/src/libautocode/generate	(revision 26712)
@@ -135,6 +135,6 @@
 	# FITS tables do not allow for 64bit integers.  we need to
 	# write these by splitting the value into high and low 32 bit values
-	if ($type eq "int64_t")       { $pt1 = "J"; $Np = 2*$Np; }
-	if ($type eq "uint64_t")      { $pt1 = "J"; $Np = 2*$Np; }
+	if ($type eq "int64_t")       { $pt1 = "K";}
+	if ($type eq "uint64_t")      { $pt1 = "K";}
 
 	if ($type eq "float")  	      { $pt1 = "E"; }
@@ -239,8 +239,6 @@
 	if ($type eq "uint32_t")      { $pt1 = sprintf "I%s", $length; }
 
-	# FITS tables do not allow for 64bit integers.  we need to
-	# write these by splitting the value into high and low 32 bit values
-	if ($type eq "int64_t")       { $pt1 = sprintf "I%s", $length; }
-	if ($type eq "uint64_t")      { $pt1 = sprintf "I%s", $length; }
+	if ($type eq "int64_t")       { $pt1 = sprintf "K%s", $length; }
+	if ($type eq "uint64_t")      { $pt1 = sprintf "K%s", $length; }
 
 	if ($type eq "float")  	      { $pt1 = sprintf "F%s", $length; }
@@ -324,8 +322,6 @@
 	if ($type eq "uint32_t")      { $T = "WORD"; $n = 4; }
 
-	# FITS tables do not allow for 64bit integers.  we need to
-	# write these by splitting the value into high and low 32 bit values
-	if ($type eq "int64_t")       { $T = "WORD"; $n = 4; $Np = 2*$Np; }
-	if ($type eq "uint64_t")      { $T = "WORD"; $n = 4; $Np = 2*$Np; }
+	if ($type eq "int64_t")       { $T = "DBLE"; $n = 8; }
+	if ($type eq "uint64_t")      { $T = "DBLE"; $n = 8; }
 
 	if ($type eq "float")  	      { $T = "WORD"; $n = 4; }
@@ -370,7 +366,4 @@
 	if ($type eq "int32_t")        { $Nbytes += 4*$Np; $valid = 1; }
 	if ($type eq "uint32_t")       { $Nbytes += 4*$Np; $valid = 1; }
-
-	# FITS tables do not allow for 64bit integers.  we need to
-	# write these by splitting the value into high and low 32 bit values
 	if ($type eq "int64_t")        { $Nbytes += 8*$Np; $valid = 1; }
 	if ($type eq "uint64_t")       { $Nbytes += 8*$Np; $valid = 1; }
