mirror of
https://github.com/nasa/trick.git
synced 2025-02-21 09:31:49 +00:00
Data Record binary endianness is determined by uninitialized variable
Initialized the variable that DRBinary is using to check for little/big endianness. fixes #60
This commit is contained in:
parent
caf79f5e45
commit
366afd27dc
@ -72,6 +72,7 @@ int Trick::DRBinary::format_specific_init() {
|
|||||||
/* Check to see if data is being recorded in little endian
|
/* Check to see if data is being recorded in little endian
|
||||||
* byte order, and add little endian line if so.
|
* byte order, and add little endian line if so.
|
||||||
*/
|
*/
|
||||||
|
byte_order_union.l = 1 ;
|
||||||
if (byte_order_union.c[sizeof(long)-1] != 1) {
|
if (byte_order_union.c[sizeof(long)-1] != 1) {
|
||||||
write( fp , "Trick-10-L", (size_t)10 ) ;
|
write( fp , "Trick-10-L", (size_t)10 ) ;
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user