Index: /OpenSceneGraph/trunk/src/osgPlugins/txp/trpage_swap.cpp
===================================================================
--- /OpenSceneGraph/trunk/src/osgPlugins/txp/trpage_swap.cpp (revision 10387)
+++ /OpenSceneGraph/trunk/src/osgPlugins/txp/trpage_swap.cpp (revision 11158)
@@ -17,4 +17,5 @@
 #include <stdio.h>
 #include <string.h>
+#include <osg/Endian>
 
 /* trpage_swap.h
@@ -23,5 +24,4 @@
 
 #include <trpage_swap.h>
-
 /*
 ** func:    swap_two( in, out )
@@ -201,7 +201,5 @@
 TX_CPPDECL trpgEndian trpg_cpu_byte_order(void)
 {
-    static char big_endian_100[2] = { 0, 100 };
-
-    if ( (*((short*) big_endian_100)) == 100 )
+    if (osg::getCpuByteOrder()==osg::BigEndian)
         return BigEndian;
     else 
