	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_eap_teap_save_pac              ## -- Begin function eap_teap_save_pac
	.p2align	4, 0x90
_eap_teap_save_pac:                     ## @eap_teap_save_pac
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	$-1, %r13d
	testq	%rdx, %rdx
	je	LBB0_12
## %bb.1:
	movq	%rdx, %r12
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	$1024, -72(%rbp)                ## imm = 0x400
	movl	$1024, %edi                     ## imm = 0x400
	callq	_os_malloc
	movq	%rax, -48(%rbp)
	testq	%rax, %rax
	je	LBB0_12
## %bb.2:
	movq	%rax, %r15
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	movq	_pac_file_hdr@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	movl	$1024, %esi                     ## imm = 0x400
	callq	_os_snprintf
	movl	%eax, %r14d
	movl	$1024, %edi                     ## imm = 0x400
	movl	%eax, %esi
	callq	_os_snprintf_error
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	%r15, %rdi
	callq	_os_free
	jmp	LBB0_12
LBB0_4:
	movslq	%r14d, %rax
	movq	%r15, %rcx
	addq	%rax, %rcx
	movq	%rcx, -64(%rbp)
	xorl	%r13d, %r13d
	testq	%rbx, %rbx
	je	LBB0_10
## %bb.5:
	leaq	-64(%rbp), %r14
	leaq	-72(%rbp), %r15
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	leaq	-48(%rbp), %rsi
	movq	%r14, %rdx
	movq	%r15, %rcx
	callq	_eap_teap_add_pac_data
	testq	%rax, %rax
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	incl	%r13d
	movq	(%rbx), %rbx
	testq	%rbx, %rbx
	jne	LBB0_6
## %bb.9:
	movq	-48(%rbp), %r15
	movq	-64(%rbp), %rcx
LBB0_10:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	subl	%r15d, %ecx
	movq	%r12, %rsi
	movq	%r15, %rdx
                                        ## kill: def $ecx killed $ecx killed $rcx
	callq	_eap_teap_write_pac
	testq	%rax, %rax
	je	LBB0_11
LBB0_7:
	movq	-48(%rbp), %rdi
	callq	_os_free
	movl	$-1, %r13d
	jmp	LBB0_12
LBB0_11:
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%r13d, %edx
	movq	%r12, %rcx
	callq	_wpa_printf
	xorl	%r13d, %r13d
LBB0_12:
	movl	%r13d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s\n"

	.comm	_pac_file_hdr,4,2               ## @pac_file_hdr
	.comm	_MSG_DEBUG,4,2                  ## @MSG_DEBUG
L_.str.1:                               ## @.str.1
	.asciz	"EAP-TEAP: Wrote %d PAC entries into '%s'"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_eap_teap_save_pac              ; -- Begin function eap_teap_save_pac
	.p2align	2
_eap_teap_save_pac:                     ; @eap_teap_save_pac
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	cbz	x2, LBB0_11
; %bb.1:
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
	mov	w8, #1024
	str	x8, [sp, #8]
	mov	w0, #1024
	bl	_os_malloc
	str	x0, [sp, #24]
	cbz	x0, LBB0_11
; %bb.2:
	mov	x23, x0
Lloh0:
	adrp	x8, _pac_file_hdr@GOTPAGE
Lloh1:
	ldr	x8, [x8, _pac_file_hdr@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	w1, #1024
	bl	_os_snprintf
	mov	x22, x0
	mov	w0, #1024
	mov	x1, x22
	bl	_os_snprintf_error
	cbz	x0, LBB0_4
; %bb.3:
	mov	x0, x23
	b	LBB0_10
LBB0_4:
	add	x8, x23, w22, sxtw
	str	x8, [sp, #16]
	mov	w22, #0
	cbz	x21, LBB0_8
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	add	x1, sp, #24
	add	x2, sp, #16
	add	x3, sp, #8
	mov	x0, x21
	bl	_eap_teap_add_pac_data
	cbnz	x0, LBB0_9
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	add	w22, w22, #1
	ldr	x21, [x21]
	cbnz	x21, LBB0_5
; %bb.7:
	ldp	x8, x23, [sp, #16]
LBB0_8:
	sub	w3, w8, w23
	mov	x0, x20
	mov	x1, x19
	mov	x2, x23
	bl	_eap_teap_write_pac
	cbz	x0, LBB0_13
LBB0_9:
	ldr	x0, [sp, #24]
LBB0_10:
	bl	_os_free
LBB0_11:
	mov	w0, #-1
LBB0_12:
	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
	add	sp, sp, #96
	ret
LBB0_13:
Lloh5:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x22
	mov	x3, x19
	bl	_wpa_printf
	mov	w0, #0
	b	LBB0_12
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s\n"

	.comm	_pac_file_hdr,4,2               ; @pac_file_hdr
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
l_.str.1:                               ; @.str.1
	.asciz	"EAP-TEAP: Wrote %d PAC entries into '%s'"

.subsections_via_symbols
