Although the code path shows this, running with -V (extra verbose) mode shows that the failure is when parsing the BT_TERM block:
... [9] 75.00% offset = 360 block_type = 0x7ffffffe 0x7ffffffe (in_addr=0 in_size=0 out_addr=673062912 out_size=0) comment +end [10] 83.33% offset = 400 block_type = 0x00000002 null bytes (out_size=0) [11] 91.67% offset = 440 block_type = 0xffffffff Segmentation fault (core dumped)
From dmg2img.h:
#define BT_TERM 0xffffffff
Although the code path shows this, running with -V (extra verbose) mode shows that the failure is when parsing the BT_TERM block:
...
[9] 75.00%
offset = 360 block_type = 0x7ffffffe
0x7ffffffe (in_addr=0 in_size=0 out_addr=673062912 out_size=0) comment +end
[10] 83.33%
offset = 400 block_type = 0x00000002
null bytes (out_size=0)
[11] 91.67%
offset = 440 block_type = 0xffffffff
Segmentation fault (core dumped)
From dmg2img.h:
#define BT_TERM 0xffffffff