	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dump_attachment
_dump_attachment:                       ## @dump_attachment
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	$0, -24(%rbp)
	movq	(%rdi), %rax
	cmpl	$0, (%rax)
	je	LBB0_9
## %bb.1:
	movq	%rsi, %rbx
	cmpb	$0, (%rsi)
	jne	LBB0_6
## %bb.2:
	movl	12(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_av_dict_get
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	(%rax), %rbx
LBB0_4:
	cmpb	$0, (%rbx)
	jne	LBB0_6
## %bb.5:
	movq	_AV_LOG_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_nb_input_files@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	decq	%rcx
	movl	8(%r14), %r8d
	leaq	L_.str.2(%rip), %rdx
	xorl	%edi, %edi
	xorl	%eax, %eax
	callq	_av_log
	movl	$1, %edi
	callq	_exit_program
LBB0_6:
	movq	%rbx, %rdi
	callq	_assert_file_overwrite
	movq	_AVIO_FLAG_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_int_cb@GOTPCREL(%rip), %rcx
	leaq	-24(%rbp), %rdi
	movq	%rbx, %rsi
	xorl	%r8d, %r8d
	callq	_avio_open2
	testl	%eax, %eax
	jns	LBB0_8
## %bb.7:
	movq	_AV_LOG_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.3(%rip), %rdx
	xorl	%edi, %edi
	movq	%rbx, %rcx
	xorl	%eax, %eax
	callq	_av_log
	movl	$1, %edi
	callq	_exit_program
LBB0_8:
	movq	-24(%rbp), %rdi
	movq	(%r14), %rax
	movl	(%rax), %edx
	movl	4(%rax), %esi
	callq	_avio_write
	movq	-24(%rbp), %rdi
	callq	_avio_flush
	movq	-24(%rbp), %rdi
	callq	_avio_close
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_9:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_nb_input_files@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	decq	%rcx
	movl	8(%r14), %r8d
	leaq	L_.str(%rip), %rdx
	xorl	%edi, %edi
	xorl	%eax, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_av_log                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No extradata to dump in stream #%d:%d.\n"

	.comm	_nb_input_files,8,3             ## @nb_input_files
L_.str.1:                               ## @.str.1
	.asciz	"filename"

	.comm	_AV_LOG_FATAL,4,2               ## @AV_LOG_FATAL
L_.str.2:                               ## @.str.2
	.asciz	"No filename specified and no 'filename' tagin stream #%d:%d.\n"

	.comm	_AVIO_FLAG_WRITE,4,2            ## @AVIO_FLAG_WRITE
	.comm	_int_cb,4,2                     ## @int_cb
L_.str.3:                               ## @.str.3
	.asciz	"Could not open file %s for writing.\n"

	.no_dead_strip	_dump_attachment
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dump_attachment
_dump_attachment:                       ; @dump_attachment
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	str	xzr, [sp, #8]
	ldr	x8, [x0]
	ldr	w8, [x8]
	cbz	w8, LBB0_9
; %bb.1:
	mov	x20, x1
	ldrb	w8, [x1]
	cbnz	w8, LBB0_6
; %bb.2:
	ldr	w0, [x19, #12]
Lloh0:
	adrp	x1, l_.str.1@PAGE
Lloh1:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, #0
	mov	w3, #0
	bl	_av_dict_get
	cbz	x0, LBB0_4
; %bb.3:
	ldr	x20, [x0]
LBB0_4:
	ldrb	w8, [x20]
	cbnz	w8, LBB0_6
; %bb.5:
Lloh2:
	adrp	x8, _AV_LOG_FATAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _AV_LOG_FATAL@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x8, _nb_input_files@GOTPAGE
Lloh6:
	ldr	x8, [x8, _nb_input_files@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	sub	x3, x8, #1
	ldr	w8, [x19, #8]
	str	x8, [sp]
Lloh8:
	adrp	x2, l_.str.2@PAGE
Lloh9:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, #0
	bl	_av_log
	mov	w0, #1
	bl	_exit_program
LBB0_6:
	mov	x0, x20
	bl	_assert_file_overwrite
Lloh10:
	adrp	x8, _AVIO_FLAG_WRITE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _AVIO_FLAG_WRITE@GOTPAGEOFF]
Lloh12:
	ldr	w2, [x8]
Lloh13:
	adrp	x3, _int_cb@GOTPAGE
Lloh14:
	ldr	x3, [x3, _int_cb@GOTPAGEOFF]
	add	x0, sp, #8
	mov	x1, x20
	mov	x4, #0
	bl	_avio_open2
	tbz	w0, #31, LBB0_8
; %bb.7:
Lloh15:
	adrp	x8, _AV_LOG_FATAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _AV_LOG_FATAL@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
Lloh18:
	adrp	x2, l_.str.3@PAGE
Lloh19:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	x0, #0
	mov	x3, x20
	bl	_av_log
	mov	w0, #1
	bl	_exit_program
LBB0_8:
	ldr	x0, [sp, #8]
	ldr	x8, [x19]
	ldp	w2, w1, [x8]
	bl	_avio_write
	ldr	x0, [sp, #8]
	bl	_avio_flush
	ldr	x0, [sp, #8]
	bl	_avio_close
	b	LBB0_10
LBB0_9:
Lloh20:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh21:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
Lloh23:
	adrp	x8, _nb_input_files@GOTPAGE
Lloh24:
	ldr	x8, [x8, _nb_input_files@GOTPAGEOFF]
Lloh25:
	ldr	x8, [x8]
	sub	x3, x8, #1
	ldr	w8, [x19, #8]
	str	x8, [sp]
Lloh26:
	adrp	x2, l_.str@PAGE
Lloh27:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, #0
	bl	_av_log
LBB0_10:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No extradata to dump in stream #%d:%d.\n"

	.comm	_nb_input_files,8,3             ; @nb_input_files
l_.str.1:                               ; @.str.1
	.asciz	"filename"

	.comm	_AV_LOG_FATAL,4,2               ; @AV_LOG_FATAL
l_.str.2:                               ; @.str.2
	.asciz	"No filename specified and no 'filename' tagin stream #%d:%d.\n"

	.comm	_AVIO_FLAG_WRITE,4,2            ; @AVIO_FLAG_WRITE
	.comm	_int_cb,4,2                     ; @int_cb
l_.str.3:                               ; @.str.3
	.asciz	"Could not open file %s for writing.\n"

	.no_dead_strip	_dump_attachment
.subsections_via_symbols
