// File: /workspace/github_c_makefile_star2_O2/jsummers[P]deark/src/fmtutil.c
// Function: fmtutil_default_box_handler
int fmtutil_default_box_handler(deark *c, struct de_boxesctx *bctx)
{
	struct de_boxdata *curbox = bctx->curbox;

	if(curbox->is_uuid) {
		if(!de_memcmp(curbox->uuid, "\xb1\x4b\xf8\xbd\x08\x3d\x4b\x43\xa5\xae\x8c\xd7\xd5\xa6\xce\x03", 16)) {
			de_dbg(c, "GeoTIFF data at %"I64_FMT", len=%"I64_FMT, curbox->payload_pos, curbox->payload_len);
			dbuf_create_file_from_slice(bctx->f, curbox->payload_pos, curbox->payload_len, "geo.tif", NULL, DE_CREATEFLAG_IS_AUX);
		}
		else if(!de_memcmp(curbox->uuid, "\xbe\x7a\xcf\xcb\x97\xa9\x42\xe8\x9c\x71\x99\x94\x91\xe3\xaf\xac", 16)) {
			de_dbg(c, "XMP data at %"I64_FMT", len=%"I64_FMT, curbox->payload_pos, curbox->payload_len);
			dbuf_create_file_from_slice(bctx->f, curbox->payload_pos, curbox->payload_len, "xmp", NULL, DE_CREATEFLAG_IS_AUX);
		}
		else if(!de_memcmp(curbox->uuid, "\x2c\x4c\x01\x00\x85\x04\x40\xb9\xa0\x3e\x56\x21\x48\xd6\xdf\xeb", 16)) {
			de_dbg(c, "Photoshop resources at %"I64_FMT", len=%"I64_FMT, curbox->payload_pos, curbox->payload_len);
			de_dbg_indent(c, 1);
			fmtutil_handle_photoshop_rsrc(c, bctx->f, curbox->payload_pos, curbox->payload_len, 0x0);
			de_dbg_indent(c, -1);
		}
		else if(!de_memcmp(curbox->uuid, "\x05\x37\xcd\xab\x9d\x0c\x44\x31\xa7\x2a\xfa\x56\x1f\x2a\x11\x3e", 16) ||
			!de_memcmp(curbox->uuid, "JpgTiffExif->JP2", 16))
		{
			de_dbg(c, "Exif data at %"I64_FMT", len=%"I64_FMT, curbox->payload_pos, curbox->payload_len);
			de_dbg_indent(c, 1);
			fmtutil_handle_exif(c, curbox->payload_pos, curbox->payload_len);
			de_dbg_indent(c, -1);
		}
	}
	return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq 0x28(%rsi), %r15
cmpl $0x0, 0x10(%r15)
je 0xeca2f
movq %rsi, %r14
movq %rdi, %rbx
movdqu 0x14(%r15), %xmm0
pcmpeqb 0x50586(%rip), %xmm0    # 0x13ce50
pmovmskb %xmm0, %eax
cmpl $0xffff, %eax           # imm = 0xFFFF
je 0xec981
leaq 0x14(%r15), %rax
movdqu (%rax), %xmm0
pcmpeqb 0x50577(%rip), %xmm0    # 0x13ce60
pmovmskb %xmm0, %ecx
cmpl $0xffff, %ecx           # imm = 0xFFFF
je 0xec9af
movdqu (%rax), %xmm0
pcmpeqb 0x5056b(%rip), %xmm0    # 0x13ce70
pmovmskb %xmm0, %ecx
cmpl $0xffff, %ecx           # imm = 0xFFFF
je 0xec9e9
movdqu (%rax), %xmm0
pcmpeqb 0x5055f(%rip), %xmm0    # 0x13ce80
pmovmskb %xmm0, %ecx
cmpl $0xffff, %ecx           # imm = 0xFFFF
je 0xec948
movdqu (%rax), %xmm0
pcmpeqb 0x50557(%rip), %xmm0    # 0x13ce90
pmovmskb %xmm0, %eax
cmpl $0xffff, %eax           # imm = 0xFFFF
jne 0xeca2f
movq 0x38(%r15), %rdx
movq 0x40(%r15), %rcx
leaq 0x507a5(%rip), %rsi     # 0x13d0fc
movq %rbx, %rdi
xorl %eax, %eax
callq 0xde896
pushq $0x1
popq %rsi
movq %rbx, %rdi
callq 0xdeba7
movq 0x38(%r15), %rsi
movq 0x40(%r15), %rdx
movq %rbx, %rdi
callq 0xec1b2
jmp 0xeca24
movq 0x38(%r15), %rdx
movq 0x40(%r15), %rcx
leaq 0x506d7(%rip), %rsi     # 0x13d067
movq %rbx, %rdi
xorl %eax, %eax
callq 0xde896
movq 0x10(%r14), %rdi
movq 0x38(%r15), %rsi
movq 0x40(%r15), %rdx
leaq 0x506d7(%rip), %rcx     # 0x13d084
jmp 0xec9db
movq 0x38(%r15), %rdx
movq 0x40(%r15), %rcx
leaq 0x506df(%rip), %rsi     # 0x13d09d
movq %rbx, %rdi
xorl %eax, %eax
callq 0xde896
movq 0x10(%r14), %rdi
movq 0x38(%r15), %rsi
movq 0x40(%r15), %rdx
leaq 0x3de23(%rip), %rcx     # 0x12a7fe
pushq $0x1
popq %r9
xorl %r8d, %r8d
callq 0xe4e0b
jmp 0xeca2f
movq 0x38(%r15), %rdx
movq 0x40(%r15), %rcx
leaq 0x506be(%rip), %rsi     # 0x13d0b6
movq %rbx, %rdi
xorl %eax, %eax
callq 0xde896
pushq $0x1
popq %rsi
movq %rbx, %rdi
callq 0xdeba7
movq 0x10(%r14), %rsi
movq 0x38(%r15), %rdx
movq 0x40(%r15), %rcx
movq %rbx, %rdi
xorl %r8d, %r8d
callq 0xec5fa
pushq $-0x1
popq %rsi
movq %rbx, %rdi
callq 0xdeba7
pushq $0x1
popq %rax
popq %rbx
popq %r14
popq %r15
retq