	.file	"extr_fts-compat.c___fts_close_44bsd.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	__fts_close_44bsd
	.type	__fts_close_44bsd, @function
__fts_close_44bsd:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	mov	rdi, QWORD PTR 56[rdi]
	test	rdi, rdi
	je	.L2
	mov	rax, QWORD PTR [rdi]
	cmp	QWORD PTR FTS_ROOTLEVEL[rip], rax
	jle	.L5
	jmp	.L28
	.p2align 4,,10
	.p2align 3
.L4:
	call	free@PLT
	mov	rax, QWORD PTR FTS_ROOTLEVEL[rip]
	cmp	QWORD PTR 0[rbp], rax
	jl	.L3
	mov	rdi, rbp
.L5:
	mov	rbp, QWORD PTR 48[rdi]
	test	rbp, rbp
	jne	.L4
	mov	rbp, QWORD PTR 40[rdi]
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L28:
	mov	rbp, rdi
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rdi, rbp
	call	free@PLT
.L2:
	mov	rdi, QWORD PTR 32[r12]
	test	rdi, rdi
	jne	.L29
.L6:
	mov	rdi, QWORD PTR 24[r12]
	test	rdi, rdi
	je	.L7
	call	free@PLT
.L7:
	mov	rdi, QWORD PTR 16[r12]
	call	free@PLT
	mov	edi, DWORD PTR FTS_NOCHDIR[rip]
	call	ISSET@PLT
	test	eax, eax
	jne	.L10
	mov	edi, DWORD PTR 8[r12]
	call	fchdir@PLT
	test	rax, rax
	je	.L30
	mov	ebp, DWORD PTR errno[rip]
	mov	edi, DWORD PTR 8[r12]
	call	_close@PLT
	test	ebp, ebp
	jne	.L31
.L10:
	mov	rdi, r12
	call	free@PLT
	xor	eax, eax
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L30:
	.cfi_restore_state
	mov	edi, DWORD PTR 8[r12]
	call	_close@PLT
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L29:
	call	fts_lfree@PLT
	jmp	.L6
.L31:
	mov	rdi, r12
	call	free@PLT
	mov	DWORD PTR errno[rip], ebp
	mov	eax, -1
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	__fts_close_44bsd, .-__fts_close_44bsd
	.comm	errno,4,4
	.comm	FTS_ROOTLEVEL,8,8
	.comm	FTS_NOCHDIR,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_fts-compat.c___fts_close_44bsd.c"
	.text
	.align	2
	.global	__fts_close_44bsd
	.syntax unified
	.arm
	.fpu softvfp
	.type	__fts_close_44bsd, %function
__fts_close_44bsd:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, [r0, #28]
	push	{r4, r5, r6, lr}
	cmp	r3, #0
	mov	r5, r0
	beq	.L2
	ldr	r6, .L32
	ldr	r2, [r3]
	ldr	r1, [r6]
	cmp	r1, r2
	ble	.L5
	b	.L28
.L13:
	mov	r3, r4
.L5:
	ldr	r4, [r3, #24]
	mov	r0, r3
	cmp	r4, #0
	ldreq	r4, [r3, #20]
	bl	free
	ldr	r2, [r4]
	ldr	r3, [r6]
	cmp	r2, r3
	bge	.L13
.L3:
	mov	r0, r4
	bl	free
.L2:
	ldr	r0, [r5, #16]
	cmp	r0, #0
	bne	.L29
.L6:
	ldr	r0, [r5, #12]
	cmp	r0, #0
	beq	.L7
	bl	free
.L7:
	ldr	r0, [r5, #8]
	bl	free
	ldr	r3, .L32+4
	ldr	r0, [r3]
	bl	ISSET
	cmp	r0, #0
	bne	.L10
	ldr	r0, [r5, #4]
	bl	fchdir
	cmp	r0, #0
	beq	.L30
	ldr	r4, .L32+8
	ldr	r0, [r5, #4]
	ldr	r6, [r4]
	bl	_close
	cmp	r6, #0
	bne	.L31
.L10:
	mov	r0, r5
	bl	free
	mov	r0, #0
	pop	{r4, r5, r6, pc}
.L30:
	ldr	r0, [r5, #4]
	bl	_close
	b	.L10
.L29:
	bl	fts_lfree
	b	.L6
.L28:
	mov	r4, r3
	b	.L3
.L31:
	mov	r0, r5
	bl	free
	mvn	r0, #0
	str	r6, [r4]
	pop	{r4, r5, r6, pc}
.L33:
	.align	2
.L32:
	.word	FTS_ROOTLEVEL
	.word	FTS_NOCHDIR
	.word	errno
	.size	__fts_close_44bsd, .-__fts_close_44bsd
	.comm	errno,4,4
	.comm	FTS_ROOTLEVEL,4,4
	.comm	FTS_NOCHDIR,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
