	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pcap_cleanup_dos
_pcap_cleanup_dos:                      ## @pcap_cleanup_dos
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	_exc_occured@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_1
LBB0_7:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_close_driver                   ## TAILCALL
LBB0_1:
	movq	%rdi, %rbx
	movq	8(%rdi), %r14
	xorl	%esi, %esi
	callq	_pcap_stats
	testq	%rax, %rax
	jns	LBB0_3
## %bb.2:
	movq	$0, (%r14)
LBB0_3:
	movl	(%rbx), %edi
	callq	_get_device
	testl	%eax, %eax
	je	LBB0_6
## %bb.4:
	movq	_handle_to_device@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	(%rbx), %rcx
	movq	$0, -8(%rax,%rcx,8)
	movl	$0, (%rbx)
	movq	_ref_count@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	testq	%rcx, %rcx
	jle	LBB0_7
## %bb.5:
	decq	%rcx
	movq	%rcx, (%rax)
	je	LBB0_7
LBB0_6:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_exc_occured,4,2                ## @exc_occured
	.comm	_handle_to_device,8,3           ## @handle_to_device
	.comm	_ref_count,8,3                  ## @ref_count
	.no_dead_strip	_pcap_cleanup_dos
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pcap_cleanup_dos
_pcap_cleanup_dos:                      ; @pcap_cleanup_dos
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, _exc_occured@GOTPAGE
Lloh1:
	ldr	x8, [x8, _exc_occured@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cbz	w8, LBB0_2
LBB0_1:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_close_driver
LBB0_2:
	mov	x19, x0
	ldr	x20, [x0, #8]
	mov	x1, #0
	bl	_pcap_stats
	tbz	x0, #63, LBB0_4
; %bb.3:
	str	xzr, [x20]
LBB0_4:
	ldr	w0, [x19]
	bl	_get_device
	cbz	w0, LBB0_7
; %bb.5:
Lloh3:
	adrp	x8, _handle_to_device@GOTPAGE
Lloh4:
	ldr	x8, [x8, _handle_to_device@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	ldrsw	x9, [x19]
	add	x8, x8, x9, lsl #3
	stur	xzr, [x8, #-8]
	str	wzr, [x19]
Lloh6:
	adrp	x8, _ref_count@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ref_count@GOTPAGEOFF]
	ldr	x9, [x8]
	subs	x9, x9, #1
	b.lt	LBB0_1
; %bb.6:
	str	x9, [x8]
	b.eq	LBB0_1
LBB0_7:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_exc_occured,4,2                ; @exc_occured
	.comm	_handle_to_device,8,3           ; @handle_to_device
	.comm	_ref_count,8,3                  ; @ref_count
	.no_dead_strip	_pcap_cleanup_dos
.subsections_via_symbols
