	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function http_shutdown
_http_shutdown:                         ## @http_shutdown
	.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	$1048, %rsp                     ## imm = 0x418
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movw	$10, -1076(%rbp)
	movl	$218762544, -1080(%rbp)         ## imm = 0xD0A0D30
	movq	(%rdi), %r12
	movq	_AVIO_FLAG_WRITE@GOTPCREL(%rip), %rax
	testl	%esi, (%rax)
	je	LBB0_2
## %bb.1:
	cmpq	$0, 24(%r12)
	jne	LBB0_5
LBB0_2:
	movq	_AVIO_FLAG_READ@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	testl	%ebx, (%rax)
	je	LBB0_10
## %bb.3:
	cmpq	$0, 24(%r12)
	je	LBB0_10
## %bb.4:
	cmpq	$0, 16(%r12)
	je	LBB0_10
LBB0_5:
	movq	8(%r12), %rdi
	leaq	-1080(%rbp), %rsi
	movl	$5, %edx
	callq	_ffurl_write
	movl	%eax, %r15d
	sarl	$31, %r15d
	andl	%eax, %r15d
	movq	_AVIO_FLAG_READ@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	jne	LBB0_9
## %bb.6:
	movq	_AVIO_FLAG_NONBLOCK@GOTPCREL(%rip), %r13
	movl	(%r13), %eax
	movq	8(%r12), %rdi
	orl	%eax, (%rdi)
	leaq	-1072(%rbp), %rsi
	movl	$1024, %edx                     ## imm = 0x400
	callq	_ffurl_read
	movl	%eax, %ebx
	movl	(%r13), %eax
	notl	%eax
	movq	8(%r12), %rcx
	andl	%eax, (%rcx)
	testl	%ebx, %ebx
	jns	LBB0_9
## %bb.7:
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	cmpl	%eax, %ebx
	je	LBB0_9
## %bb.8:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	%ebx, %edi
	callq	_av_err2str
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %ecx
	callq	_av_log
	movl	%ebx, %r15d
LBB0_9:
	movl	$1, (%r12)
LBB0_10:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_12
## %bb.11:
	movl	%r15d, %eax
	addq	$1048, %rsp                     ## imm = 0x418
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L___const.http_shutdown.footer:         ## @__const.http_shutdown.footer
	.asciz	"0\r\n\r\n"

	.comm	_AVIO_FLAG_WRITE,4,2            ## @AVIO_FLAG_WRITE
	.comm	_AVIO_FLAG_READ,4,2             ## @AVIO_FLAG_READ
	.comm	_AVIO_FLAG_NONBLOCK,4,2         ## @AVIO_FLAG_NONBLOCK
	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
L_.str:                                 ## @.str
	.asciz	"URL read error: %s\n"

	.no_dead_strip	_http_shutdown
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function http_shutdown
_http_shutdown:                         ; @http_shutdown
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	sub	sp, sp, #1040
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	mov	w8, #10
	strh	w8, [sp, #4]
	mov	w8, #3376
	movk	w8, #3338, lsl #16
	str	w8, [sp]
	ldr	x22, [x0]
Lloh3:
	adrp	x8, _AVIO_FLAG_WRITE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AVIO_FLAG_WRITE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x23, _AVIO_FLAG_READ@GOTPAGE
Lloh7:
	ldr	x23, [x23, _AVIO_FLAG_READ@GOTPAGEOFF]
	tst	w8, w1
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x22, #24]
	cbnz	x8, LBB0_5
LBB0_2:
	ldr	w8, [x23]
	tst	w8, w21
	b.eq	LBB0_10
; %bb.3:
	ldr	x8, [x22, #24]
	cbz	x8, LBB0_10
; %bb.4:
	ldr	x8, [x22, #16]
	cbz	x8, LBB0_10
LBB0_5:
	ldr	x0, [x22, #8]
	mov	x1, sp
	mov	w2, #5
	bl	_ffurl_write
	cmp	w0, #0
	csel	w20, w0, wzr, lt
	ldr	w8, [x23]
	tst	w8, w21
	b.ne	LBB0_9
; %bb.6:
Lloh8:
	adrp	x23, _AVIO_FLAG_NONBLOCK@GOTPAGE
Lloh9:
	ldr	x23, [x23, _AVIO_FLAG_NONBLOCK@GOTPAGEOFF]
	ldr	w8, [x23]
	ldr	x0, [x22, #8]
	ldr	w9, [x0]
	orr	w8, w9, w8
	str	w8, [x0]
	add	x1, sp, #8
	mov	w2, #1024
	bl	_ffurl_read
	ldr	w8, [x23]
	ldr	x9, [x22, #8]
	ldr	w10, [x9]
	bic	w8, w10, w8
	str	w8, [x9]
	tbz	w0, #31, LBB0_9
; %bb.7:
	mov	x21, x0
Lloh10:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
	bl	_AVERROR
	cmp	w21, w0
	b.eq	LBB0_9
; %bb.8:
Lloh13:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh14:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh15:
	ldr	w20, [x8]
	mov	x0, x21
	bl	_av_err2str
	mov	x3, x0
Lloh16:
	adrp	x2, l_.str@PAGE
Lloh17:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	mov	x1, x20
	bl	_av_log
	mov	x20, x21
LBB0_9:
	mov	w8, #1
	str	w8, [x22]
	b	LBB0_11
LBB0_10:
	mov	w20, #0
LBB0_11:
	ldur	x8, [x29, #-56]
Lloh18:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh19:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_13
; %bb.12:
	mov	x0, x20
	add	sp, sp, #1040
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_13:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l___const.http_shutdown.footer:         ; @__const.http_shutdown.footer
	.asciz	"0\r\n\r\n"

	.comm	_AVIO_FLAG_WRITE,4,2            ; @AVIO_FLAG_WRITE
	.comm	_AVIO_FLAG_READ,4,2             ; @AVIO_FLAG_READ
	.comm	_AVIO_FLAG_NONBLOCK,4,2         ; @AVIO_FLAG_NONBLOCK
	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
l_.str:                                 ; @.str
	.asciz	"URL read error: %s\n"

	.no_dead_strip	_http_shutdown
.subsections_via_symbols
