	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function write_cdir
_write_cdir:                            ## @write_cdir
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r13
	movl	%edx, %r12d
	movq	%rsi, %r14
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	%rsp, -80(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_TORRENT_CRC_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	incl	%ebx
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, -72(%rbp)                 ## 8-byte Spill
	movq	%r13, %rdi
	callq	_ftello
	testq	%rax, %rax
	js	LBB0_9
## %bb.1:
	movq	%rax, %r15
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%r14, %rsi
	movl	%r12d, %edx
	movq	%r13, %rcx
	callq	__zip_cdir_write
	testl	%eax, %eax
	js	LBB0_9
## %bb.2:
	movl	%eax, %r14d
	movq	%r13, %rdi
	callq	_ftello
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	_ZIP_AFL_TORRENT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r12d, %r12d
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	xorl	%edx, %edx
	callq	_zip_get_archive_flag
	testq	%rax, %rax
	je	LBB0_10
## %bb.3:
	leaq	-88(%rbp), %rcx
	movq	%r13, %rdi
	movq	%r15, %rsi
	movl	%r14d, %edx
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %r8
	callq	__zip_filerange_crc
	testq	%rax, %rax
	js	LBB0_9
## %bb.4:
	movq	-88(%rbp), %rcx
	leaq	L_.str(%rip), %rdx
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_snprintf
	movq	_TORRENT_CRC_LEN@GOTPCREL(%rip), %rbx
	movslq	(%rbx), %rax
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	subq	%rax, %rsi
	movq	_SEEK_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	callq	_fseeko
	testq	%rax, %rax
	js	LBB0_5
## %bb.6:
	movl	(%rbx), %esi
	movq	%r15, %rdi
	movl	$1, %edx
	movq	%r13, %rcx
	callq	_fwrite
	cmpl	$1, %eax
	je	LBB0_10
## %bb.7:
	movq	_ZIP_ER_WRITE@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_5:
	movq	_ZIP_ER_SEEK@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %esi
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	__zip_error_set
LBB0_9:
	movl	$-1, %r12d
LBB0_10:
	movq	-80(%rbp), %rsp                 ## 8-byte Reload
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_12
## %bb.11:
	movl	%r12d, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_TORRENT_CRC_LEN,4,2            ## @TORRENT_CRC_LEN
	.comm	_ZIP_AFL_TORRENT,4,2            ## @ZIP_AFL_TORRENT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%08lX"

	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
	.comm	_ZIP_ER_SEEK,4,2                ## @ZIP_ER_SEEK
	.comm	_errno,4,2                      ## @errno
	.comm	_ZIP_ER_WRITE,4,2               ## @ZIP_ER_WRITE
	.no_dead_strip	_write_cdir
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function write_cdir
_write_cdir:                            ; @write_cdir
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #16
	mov	x20, x3
	mov	x23, x2
	mov	x25, x1
	mov	x19, x0
	mov	x26, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x27, _TORRENT_CRC_LEN@GOTPAGE
Lloh4:
	ldr	x27, [x27, _TORRENT_CRC_LEN@GOTPAGEOFF]
	ldr	w8, [x27]
	add	w22, w8, #1
	mov	x9, x22
Lloh5:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh6:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x22, #15
	and	x9, x9, #0x1fffffff0
	sub	x21, x8, x9
	mov	sp, x21
	mov	x0, x3
	bl	_ftello
	tbnz	x0, #63, LBB0_10
; %bb.1:
	mov	x24, x0
	mov	x0, x19
	mov	x1, x25
	mov	x2, x23
	mov	x3, x20
	bl	__zip_cdir_write
	tbnz	w0, #31, LBB0_10
; %bb.2:
	mov	x25, x0
	mov	x0, x20
	bl	_ftello
	mov	x23, x0
Lloh7:
	adrp	x8, _ZIP_AFL_TORRENT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ZIP_AFL_TORRENT@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_zip_get_archive_flag
	cbz	x0, LBB0_11
; %bb.3:
	sub	x3, x29, #96
	mov	x0, x20
	mov	x1, x24
	mov	x2, x25
	mov	x4, x19
	bl	__zip_filerange_crc
	tbnz	x0, #63, LBB0_10
; %bb.4:
	ldur	x3, [x29, #-96]
Lloh10:
	adrp	x2, l_.str@PAGE
Lloh11:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x21
	mov	x1, x22
	bl	_snprintf
	ldrsw	x8, [x27]
	sub	x1, x23, x8
Lloh12:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_fseeko
	tbnz	x0, #63, LBB0_7
; %bb.5:
	ldr	w1, [x27]
	mov	x0, x21
	mov	w2, #1
	mov	x3, x20
	bl	_fwrite
	cmp	w0, #1
	b.ne	LBB0_8
; %bb.6:
	mov	w0, #0
	b	LBB0_11
LBB0_7:
Lloh15:
	adrp	x8, _ZIP_ER_SEEK@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ZIP_ER_SEEK@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh17:
	adrp	x8, _ZIP_ER_WRITE@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ZIP_ER_WRITE@GOTPAGEOFF]
LBB0_9:
	ldr	w1, [x8]
Lloh19:
	adrp	x8, _errno@GOTPAGE
Lloh20:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh21:
	ldr	w2, [x8]
	mov	x0, x19
	bl	__zip_error_set
LBB0_10:
	mov	w0, #-1
LBB0_11:
	mov	sp, x26
	ldur	x8, [x29, #-88]
Lloh22:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh23:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_13
; %bb.12:
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_13:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_TORRENT_CRC_LEN,4,2            ; @TORRENT_CRC_LEN
	.comm	_ZIP_AFL_TORRENT,4,2            ; @ZIP_AFL_TORRENT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%08lX"

	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
	.comm	_ZIP_ER_SEEK,4,2                ; @ZIP_ER_SEEK
	.comm	_errno,4,2                      ; @errno
	.comm	_ZIP_ER_WRITE,4,2               ; @ZIP_ER_WRITE
	.no_dead_strip	_write_cdir
.subsections_via_symbols
