4 ms·
This isn't extremely important, but you should probably declare those symbols as straight `char`'s, not `void * `. The symbols themselves aren't pointers, the s
by DSMan195276 11y ago
This isn't extremely important, but you should probably declare those symbols as straight `char`'s, not `void * `. The symbols themselves aren't pointers, the symbol itself refers to the first byte in your binary block - The same way `b` from `char b` refers to a byte on the stack. That's why you have to take the address of the symbol to get the address of the block. It makes more sense to declare it as a `char` because then nobody will attempt to use the original block symbols to access the blob itself.
As it is, you have `_binary_blob_start`, `start`, `_binary_blob_end` and `end`. All 4 are `void * `'s, but `start` and `end` are the only ones which actually point to the block! `_binary_blob_start` and `_binary_blob_end` are actually pointers made-up of the first 4/8 bytes of your binary-data, and thus aren't actually pointers.