Move options files from <build_dir>/build_options to build_options/<build_dir>.
[gem5.git] / dev / disk_image.cc
index 20e693d0d566add95af8392e33853d4c1094dffc..106723c554d50ecacdd0f817d14d5b306fd3967b 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001-2004 The Regents of The University of Michigan
+ * Copyright (c) 2001-2005 The Regents of The University of Michigan
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -26,7 +26,7 @@
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-/* @file
+/** @file
  * Disk Image Definitions
  */
 
@@ -237,7 +237,7 @@ void
 SafeReadSwap(ifstream &stream, T &data)
 {
     SafeRead(stream, &data, sizeof(data));
-    data = htoa(data);
+    data = letoh(data); //is this the proper byte order conversion?
 }
 
 bool
@@ -319,7 +319,7 @@ template<class T>
 void
 SafeWriteSwap(ofstream &stream, const T &data)
 {
-    T swappeddata = htoa(data);
+    T swappeddata = letoh(data); //is this the proper byte order conversion?
     SafeWrite(stream, &swappeddata, sizeof(data));
 }
 void