	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_scan_dump                      ## -- Begin function scan_dump
	.p2align	4, 0x90
_scan_dump:                             ## @scan_dump
	.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
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	_SEEK_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%esi, %esi
	callq	_fseek
	leaq	-88(%rbp), %rdi
	movl	$1, %r15d
	movl	$40, %esi
	movl	$1, %edx
	movq	%rbx, %rcx
	callq	_fread
	cmpl	$1, %eax
	jne	LBB0_1
## %bb.2:
	movq	-88(%rbp), %rax
	movq	_TCPDUMP_MAGIC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_21
## %bb.3:
	movq	-80(%rbp), %rax
	movq	_PCAP_VERSION_MAJOR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_21
## %bb.4:
	movq	-72(%rbp), %rax
	movq	_PCAP_VERSION_MINOR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_21
## %bb.5:
	movq	-64(%rbp), %rax
	movq	_hpcap@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_21
## %bb.6:
	movq	-56(%rbp), %r12
	movq	_PFLOGD_MAXSNAPLEN@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r12
	jg	LBB0_21
## %bb.7:
	movq	%rbx, %rdi
	callq	_feof
	movl	$40, %r13d
	testl	%eax, %eax
	je	LBB0_8
LBB0_17:
	cmpl	%r14d, %r13d
	jne	LBB0_11
## %bb.18:
	movq	_cur_snaplen@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	cmpq	(%rax), %r12
	je	LBB0_21
## %bb.19:
	movq	_LOG_WARNING@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r12, %rdx
	xorl	%eax, %eax
	callq	_logmsg
	movq	%r12, %rdi
	callq	_set_snaplen
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	movl	(%rbx), %edi
	movslq	%r14d, %rdx
	leaq	L_.str.2(%rip), %rsi
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_logmsg
	jmp	LBB0_21
LBB0_1:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
LBB0_12:
	xorl	%eax, %eax
	callq	_logmsg
LBB0_21:
	movl	%r15d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movl	$40, %r13d
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	leaq	-48(%rbp), %rdi
	movl	$1, %esi
	movl	$8, %edx
	movq	%rbx, %rcx
	callq	_fread
	cmpl	$8, %eax
	jne	LBB0_10
## %bb.13:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	-48(%rbp), %rsi
	cmpq	%r12, %rsi
	jg	LBB0_11
## %bb.14:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	_PFLOGD_MAXSNAPLEN@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rsi
	jg	LBB0_11
## %bb.15:                              ##   in Loop: Header=BB0_9 Depth=1
	addl	%esi, %r13d
	addl	$8, %r13d
	cmpl	%r14d, %r13d
	jg	LBB0_11
## %bb.16:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	_SEEK_CUR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_fseek
	movq	%rbx, %rdi
	callq	_feof
	testl	%eax, %eax
	je	LBB0_9
	jmp	LBB0_17
LBB0_10:
	testl	%eax, %eax
	je	LBB0_17
LBB0_11:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
	.comm	_LOG_ERR,4,2                    ## @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Short file header"

	.comm	_TCPDUMP_MAGIC,8,3              ## @TCPDUMP_MAGIC
	.comm	_PCAP_VERSION_MAJOR,8,3         ## @PCAP_VERSION_MAJOR
	.comm	_PCAP_VERSION_MINOR,8,3         ## @PCAP_VERSION_MINOR
	.comm	_hpcap,8,3                      ## @hpcap
	.comm	_PFLOGD_MAXSNAPLEN,8,3          ## @PFLOGD_MAXSNAPLEN
	.comm	_SEEK_CUR,4,2                   ## @SEEK_CUR
	.comm	_cur_snaplen,8,3                ## @cur_snaplen
	.comm	_LOG_WARNING,4,2                ## @LOG_WARNING
L_.str.1:                               ## @.str.1
	.asciz	"Existing file has different snaplen %u, using it"

L_.str.2:                               ## @.str.2
	.asciz	"Failed, using old settings, offset %llu"

L_.str.3:                               ## @.str.3
	.asciz	"Corrupted log file."

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_scan_dump                      ; -- Begin function scan_dump
	.p2align	2
_scan_dump:                             ; @scan_dump
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x1, #0
	bl	_fseek
	add	x0, sp, #24
	mov	w1, #40
	mov	w2, #1
	mov	x3, x20
	bl	_fread
	cmp	w0, #1
	b.ne	LBB0_12
; %bb.1:
	ldr	x8, [sp, #24]
Lloh3:
	adrp	x9, _TCPDUMP_MAGIC@GOTPAGE
Lloh4:
	ldr	x9, [x9, _TCPDUMP_MAGIC@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_14
; %bb.2:
	ldr	x8, [sp, #32]
Lloh6:
	adrp	x9, _PCAP_VERSION_MAJOR@GOTPAGE
Lloh7:
	ldr	x9, [x9, _PCAP_VERSION_MAJOR@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_14
; %bb.3:
	ldr	x8, [sp, #40]
Lloh9:
	adrp	x9, _PCAP_VERSION_MINOR@GOTPAGE
Lloh10:
	ldr	x9, [x9, _PCAP_VERSION_MINOR@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_14
; %bb.4:
	ldr	x8, [sp, #48]
Lloh12:
	adrp	x9, _hpcap@GOTPAGE
Lloh13:
	ldr	x9, [x9, _hpcap@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_14
; %bb.5:
	ldr	x21, [sp, #56]
Lloh15:
	adrp	x22, _PFLOGD_MAXSNAPLEN@GOTPAGE
Lloh16:
	ldr	x22, [x22, _PFLOGD_MAXSNAPLEN@GOTPAGEOFF]
	ldr	x8, [x22]
	cmp	x21, x8
	b.gt	LBB0_14
; %bb.6:
	mov	x0, x20
	bl	_feof
	mov	w23, #40
	cbz	w0, LBB0_16
LBB0_7:
	cmp	w23, w19
	b.ne	LBB0_21
; %bb.8:
Lloh17:
	adrp	x8, _cur_snaplen@GOTPAGE
Lloh18:
	ldr	x8, [x8, _cur_snaplen@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
	cmp	x21, x8
	b.eq	LBB0_11
; %bb.9:
Lloh20:
	adrp	x20, _LOG_WARNING@GOTPAGE
Lloh21:
	ldr	x20, [x20, _LOG_WARNING@GOTPAGEOFF]
	ldr	w0, [x20]
	str	x21, [sp]
Lloh22:
	adrp	x1, l_.str.1@PAGE
Lloh23:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_logmsg
	mov	x0, x21
	bl	_set_snaplen
	cbz	x0, LBB0_15
; %bb.10:
	ldr	w0, [x20]
	sxtw	x8, w19
	str	x8, [sp]
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_logmsg
LBB0_11:
	mov	w0, #0
	b	LBB0_15
LBB0_12:
Lloh26:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh27:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
Lloh29:
	adrp	x1, l_.str@PAGE
Lloh30:
	add	x1, x1, l_.str@PAGEOFF
LBB0_13:
	bl	_logmsg
LBB0_14:
	mov	w0, #1
LBB0_15:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_16:
Lloh31:
	adrp	x24, _SEEK_CUR@GOTPAGE
Lloh32:
	ldr	x24, [x24, _SEEK_CUR@GOTPAGEOFF]
LBB0_17:                                ; =>This Inner Loop Header: Depth=1
	add	x0, sp, #16
	mov	w1, #1
	mov	w2, #8
	mov	x3, x20
	bl	_fread
	cmp	w0, #8
	b.ne	LBB0_20
; %bb.18:                               ;   in Loop: Header=BB0_17 Depth=1
	ldr	x1, [sp, #16]
	ldr	x8, [x22]
	cmp	x1, x21
	ccmp	x1, x8, #0, le
	add	w8, w23, w1
	add	w23, w8, #8
	ccmp	w23, w19, #0, le
	b.gt	LBB0_21
; %bb.19:                               ;   in Loop: Header=BB0_17 Depth=1
	ldr	w2, [x24]
	mov	x0, x20
	bl	_fseek
	mov	x0, x20
	bl	_feof
	cbz	w0, LBB0_17
	b	LBB0_7
LBB0_20:
	cbz	w0, LBB0_7
LBB0_21:
Lloh33:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh34:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh35:
	ldr	w0, [x8]
Lloh36:
	adrp	x1, l_.str.3@PAGE
Lloh37:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_13
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
	.comm	_LOG_ERR,4,2                    ; @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Short file header"

	.comm	_TCPDUMP_MAGIC,8,3              ; @TCPDUMP_MAGIC
	.comm	_PCAP_VERSION_MAJOR,8,3         ; @PCAP_VERSION_MAJOR
	.comm	_PCAP_VERSION_MINOR,8,3         ; @PCAP_VERSION_MINOR
	.comm	_hpcap,8,3                      ; @hpcap
	.comm	_PFLOGD_MAXSNAPLEN,8,3          ; @PFLOGD_MAXSNAPLEN
	.comm	_SEEK_CUR,4,2                   ; @SEEK_CUR
	.comm	_cur_snaplen,8,3                ; @cur_snaplen
	.comm	_LOG_WARNING,4,2                ; @LOG_WARNING
l_.str.1:                               ; @.str.1
	.asciz	"Existing file has different snaplen %u, using it"

l_.str.2:                               ; @.str.2
	.asciz	"Failed, using old settings, offset %llu"

l_.str.3:                               ; @.str.3
	.asciz	"Corrupted log file."

.subsections_via_symbols
