# HG changeset patch # User Mike Miller # Date 1464204530 25200 # Node ID d6826b38b29ced0b059dd1137990cd4bdcb96631 # Parent 6cf6bc451eeb3729432e2150fff736a0e928d8ff# Parent 1e81dd035639a8da963982f6a98e6e742b7eea22 maint: Periodic merge of stable to default. diff -r 6cf6bc451eeb -r d6826b38b29c libinterp/corefcn/oct-stream.cc --- a/libinterp/corefcn/oct-stream.cc Wed May 25 09:35:37 2016 -0500 +++ b/libinterp/corefcn/oct-stream.cc Wed May 25 12:28:50 2016 -0700 @@ -6697,10 +6697,12 @@ { bool retval = true; - bool swap - = ((octave::mach_info::words_big_endian () - && flt_fmt == octave::mach_info::flt_fmt_ieee_little_endian) - || flt_fmt == octave::mach_info::flt_fmt_ieee_big_endian); + bool swap = false; + + if (octave::mach_info::words_big_endian ()) + swap = (flt_fmt == octave::mach_info::flt_fmt_ieee_little_endian); + else + swap = (flt_fmt == octave::mach_info::flt_fmt_ieee_big_endian); bool do_float_conversion = flt_fmt != octave::mach_info::float_format (); @@ -6860,9 +6862,12 @@ octave_idx_type skip, octave::mach_info::float_format flt_fmt) { - bool swap = ((octave::mach_info::words_big_endian () - && flt_fmt == octave::mach_info::flt_fmt_ieee_little_endian) - || flt_fmt == octave::mach_info::flt_fmt_ieee_big_endian); + bool swap = false; + + if (octave::mach_info::words_big_endian ()) + swap = (flt_fmt == octave::mach_info::flt_fmt_ieee_little_endian); + else + swap = (flt_fmt == octave::mach_info::flt_fmt_ieee_big_endian); bool do_data_conversion = (swap || ! is_equivalent_type (output_type) || flt_fmt != octave::mach_info::float_format ());