File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed
Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -85,7 +85,8 @@ osx_fat_readert::osx_fat_readert(
8585 if (!in)
8686 throw system_exceptiont (" failed to read OSX fat header" );
8787
88- if (!is_osx_fat_header (reinterpret_cast <char *>(&(fh.magic ))))
88+ static_assert (sizeof (fh) >= 8 , " fat_header is at least 8 bytes" );
89+ if (!is_osx_fat_header (reinterpret_cast <char *>(&fh)))
8990 throw deserialization_exceptiont (" OSX fat header malformed" );
9091
9192 static_assert (
Original file line number Diff line number Diff line change @@ -74,6 +74,6 @@ class osx_mach_o_readert
7474 void process_sections_64 (uint32_t nsects, bool need_swap);
7575};
7676
77- bool is_osx_mach_object (char hdr[8 ]);
77+ bool is_osx_mach_object (char hdr[4 ]);
7878
7979#endif // CPROVER_GOTO_PROGRAMS_OSX_FAT_READER_H
You can’t perform that action at this time.
0 commit comments