| OLD | NEW |
| 1 // Copyright (c) 2006, Google Inc. | 1 // Copyright (c) 2006, Google Inc. |
| 2 // All rights reserved. | 2 // All rights reserved. |
| 3 // | 3 // |
| 4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
| 5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
| 6 // met: | 6 // met: |
| 7 // | 7 // |
| 8 // * Redistributions of source code must retain the above copyright | 8 // * Redistributions of source code must retain the above copyright |
| 9 // notice, this list of conditions and the following disclaimer. | 9 // notice, this list of conditions and the following disclaimer. |
| 10 // * Redistributions in binary form must reproduce the above | 10 // * Redistributions in binary form must reproduce the above |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 #endif | 55 #endif |
| 56 | 56 |
| 57 // The uuid_command struct/swap routines were added during the 10.4 series. | 57 // The uuid_command struct/swap routines were added during the 10.4 series. |
| 58 // Their presence isn't guaranteed. | 58 // Their presence isn't guaranteed. |
| 59 struct breakpad_uuid_command { | 59 struct breakpad_uuid_command { |
| 60 uint32_t cmd; /* LC_UUID */ | 60 uint32_t cmd; /* LC_UUID */ |
| 61 uint32_t cmdsize; /* sizeof(struct uuid_command) */ | 61 uint32_t cmdsize; /* sizeof(struct uuid_command) */ |
| 62 uint8_t uuid[16]; /* the 128-bit uuid */ | 62 uint8_t uuid[16]; /* the 128-bit uuid */ |
| 63 }; | 63 }; |
| 64 | 64 |
| 65 void breakpad_swap_uuid_command(struct breakpad_uuid_command *uc, | 65 void breakpad_swap_uuid_command(struct breakpad_uuid_command *uc); |
| 66 enum NXByteOrder target_byte_order); | 66 |
| 67 void breakpad_swap_load_command(struct load_command *lc); |
| 68 |
| 69 void breakpad_swap_dylib_command(struct dylib_command *dc); |
| 67 | 70 |
| 68 // Older SDKs defines thread_state_data_t as an int[] instead | 71 // Older SDKs defines thread_state_data_t as an int[] instead |
| 69 // of the natural_t[] it should be. | 72 // of the natural_t[] it should be. |
| 70 typedef natural_t breakpad_thread_state_data_t[THREAD_STATE_MAX]; | 73 typedef natural_t breakpad_thread_state_data_t[THREAD_STATE_MAX]; |
| 71 | 74 |
| 75 void breakpad_swap_segment_command(struct segment_command *sc); |
| 76 |
| 72 // The 64-bit swap routines were added during the 10.4 series, their | 77 // The 64-bit swap routines were added during the 10.4 series, their |
| 73 // presence isn't guaranteed. | 78 // presence isn't guaranteed. |
| 74 void breakpad_swap_segment_command_64(struct segment_command_64 *sg, | 79 void breakpad_swap_segment_command_64(struct segment_command_64 *sg); |
| 75 enum NXByteOrder target_byte_order); | |
| 76 | 80 |
| 77 void breakpad_swap_mach_header_64(struct mach_header_64 *mh, | 81 void breakpad_swap_fat_header(struct fat_header *fh); |
| 78 enum NXByteOrder target_byte_order); | 82 |
| 83 void breakpad_swap_fat_arch(struct fat_arch *fa, uint32_t narchs); |
| 84 |
| 85 void breakpad_swap_mach_header(struct mach_header *mh); |
| 86 |
| 87 void breakpad_swap_mach_header_64(struct mach_header_64 *mh); |
| 88 |
| 89 void breakpad_swap_section(struct section *s, |
| 90 uint32_t nsects); |
| 79 | 91 |
| 80 void breakpad_swap_section_64(struct section_64 *s, | 92 void breakpad_swap_section_64(struct section_64 *s, |
| 81 uint32_t nsects, | 93 uint32_t nsects); |
| 82 enum NXByteOrder target_byte_order); | |
| 83 | 94 |
| 84 #endif | 95 #endif |
| OLD | NEW |