	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ftpd_pclose                    ## -- Begin function ftpd_pclose
	.p2align	4, 0x90
_ftpd_pclose:                           ## @ftpd_pclose
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_pids@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movl	$-1, %ebx
	testq	%r15, %r15
	je	LBB0_9
## %bb.1:
	movq	%rdi, %r14
	callq	_fileno
	movslq	%eax, %r12
	cmpq	$0, (%r15,%r12,8)
	je	LBB0_9
## %bb.2:
	movq	%r14, %rdi
	callq	_fclose
	leaq	-52(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_sigemptyset
	movq	_SIGINT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_sigaddset
	movq	_SIGQUIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_sigaddset
	movq	_SIGHUP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_sigaddset
	movq	_SIG_BLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-48(%rbp), %rdx
	movq	%rbx, %rsi
	callq	_sigprocmask
	leaq	-44(%rbp), %r14
	movq	_errno@GOTPCREL(%rip), %r13
	movq	_EINTR@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	_pids@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax,%r12,8), %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	callq	_waitpid
	movq	%rax, %rbx
	testq	%rax, %rax
	jns	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	(%r15), %rax
	cmpq	%rax, (%r13)
	je	LBB0_3
LBB0_5:
	movq	_SIG_SETMASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-48(%rbp), %rsi
	xorl	%edx, %edx
	callq	_sigprocmask
	movq	_pids@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	$0, (%rax,%r12,8)
	testq	%rbx, %rbx
	js	LBB0_9
## %bb.6:
	movl	-44(%rbp), %edi
	callq	_WIFEXITED
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movl	-44(%rbp), %edi
	callq	_WEXITSTATUS
	movl	%eax, %ebx
	jmp	LBB0_9
LBB0_7:
	movl	$1, %ebx
LBB0_9:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_pids,8,3                       ## @pids
	.comm	_SIGINT,4,2                     ## @SIGINT
	.comm	_SIGQUIT,4,2                    ## @SIGQUIT
	.comm	_SIGHUP,4,2                     ## @SIGHUP
	.comm	_SIG_BLOCK,4,2                  ## @SIG_BLOCK
	.comm	_errno,8,3                      ## @errno
	.comm	_EINTR,8,3                      ## @EINTR
	.comm	_SIG_SETMASK,4,2                ## @SIG_SETMASK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ftpd_pclose                    ; -- Begin function ftpd_pclose
	.p2align	2
_ftpd_pclose:                           ; @ftpd_pclose
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
Lloh0:
	adrp	x20, _pids@GOTPAGE
Lloh1:
	ldr	x20, [x20, _pids@GOTPAGEOFF]
	ldr	x21, [x20]
	cbz	x21, LBB0_8
; %bb.1:
	mov	x19, x0
	bl	_fileno
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	x8, [x21, w0, sxtw #3]
	cbz	x8, LBB0_8
; %bb.2:
	sxtw	x21, w0
	mov	x0, x19
	bl	_fclose
	add	x0, sp, #8
	bl	_sigemptyset
Lloh2:
	adrp	x8, _SIGINT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _SIGINT@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	add	x0, sp, #8
	bl	_sigaddset
Lloh5:
	adrp	x8, _SIGQUIT@GOTPAGE
Lloh6:
	ldr	x8, [x8, _SIGQUIT@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	add	x0, sp, #8
	bl	_sigaddset
Lloh8:
	adrp	x8, _SIGHUP@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SIGHUP@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	add	x0, sp, #8
	bl	_sigaddset
Lloh11:
	adrp	x8, _SIG_BLOCK@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SIG_BLOCK@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	add	x1, sp, #8
	add	x2, sp, #4
	bl	_sigprocmask
Lloh14:
	adrp	x22, _errno@GOTPAGE
Lloh15:
	ldr	x22, [x22, _errno@GOTPAGEOFF]
Lloh16:
	adrp	x23, _EINTR@GOTPAGE
Lloh17:
	ldr	x23, [x23, _EINTR@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x20]
	ldr	x0, [x8, x21, lsl #3]
	add	x1, sp, #12
	mov	w2, #0
	bl	_waitpid
	mov	x19, x0
	tbz	x0, #63, LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x22]
	ldr	x9, [x23]
	cmp	x8, x9
	b.eq	LBB0_3
LBB0_5:
Lloh18:
	adrp	x8, _SIG_SETMASK@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SIG_SETMASK@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	add	x1, sp, #4
	mov	x2, #0
	bl	_sigprocmask
	ldr	x8, [x20]
	str	xzr, [x8, x21, lsl #3]
	tbnz	x19, #63, LBB0_9
; %bb.6:
	ldr	w0, [sp, #12]
	bl	_WIFEXITED
	cbz	x0, LBB0_10
; %bb.7:
	ldr	w0, [sp, #12]
	bl	_WEXITSTATUS
	mov	x19, x0
	b	LBB0_9
LBB0_8:
	mov	w19, #-1
LBB0_9:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_10:
	mov	w19, #1
	b	LBB0_9
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_pids,8,3                       ; @pids
	.comm	_SIGINT,4,2                     ; @SIGINT
	.comm	_SIGQUIT,4,2                    ; @SIGQUIT
	.comm	_SIGHUP,4,2                     ; @SIGHUP
	.comm	_SIG_BLOCK,4,2                  ; @SIG_BLOCK
	.comm	_errno,8,3                      ; @errno
	.comm	_EINTR,8,3                      ; @EINTR
	.comm	_SIG_SETMASK,4,2                ; @SIG_SETMASK
.subsections_via_symbols
