	.file	"146973.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"Failed to open directory"
	.align 8
.LC1:
	.string	"Failed to get current working directory"
.LC2:
	.string	"."
.LC3:
	.string	".."
.LC4:
	.string	"%s\t"
.LC5:
	.string	"Failed to open file"
	.text
	.globl	print
	.type	print, @function
print:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 160
	mov	QWORD PTR -4248[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -4248[rbp]
	mov	rdi, rax
	call	opendir@PLT
	mov	QWORD PTR -4224[rbp], rax
	cmp	QWORD PTR -4224[rbp], 0
	jne	.L2
	lea	rdi, .LC0[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L15
.L2:
	lea	rax, -4112[rbp]
	mov	esi, 4096
	mov	rdi, rax
	call	getcwd@PLT
	test	rax, rax
	jne	.L4
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L15
.L4:
	lea	rax, -4112[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rax, -4112[rbp]
	add	rax, rdx
	mov	WORD PTR [rax], 47
	mov	rdx, QWORD PTR -4248[rbp]
	lea	rax, -4112[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcat@PLT
	lea	rax, -4112[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rax, -4112[rbp]
	add	rax, rdx
	mov	WORD PTR [rax], 47
	jmp	.L5
.L12:
	mov	rax, QWORD PTR -4216[rbp]
	add	rax, 19
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L6
	jmp	.L5
.L6:
	mov	rax, QWORD PTR -4216[rbp]
	add	rax, 19
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L7
	jmp	.L5
.L7:
	mov	rax, QWORD PTR -4216[rbp]
	add	rax, 19
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdx, -4112[rbp]
	lea	rax, -4176[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcpy@PLT
	mov	rax, QWORD PTR -4216[rbp]
	lea	rdx, 19[rax]
	lea	rax, -4176[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcat@PLT
	lea	rax, -4176[rbp]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -4228[rbp], eax
	cmp	DWORD PTR -4228[rbp], -1
	jne	.L17
	lea	rdi, .LC5[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L15
.L17:
	nop
.L10:
	lea	rcx, -4208[rbp]
	mov	eax, DWORD PTR -4228[rbp]
	mov	edx, 20
	mov	rsi, rcx
	mov	edi, eax
	mov	eax, 0
	call	readline@PLT
	cmp	eax, -1
	jne	.L9
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 4
	je	.L10
.L9:
	lea	rax, -4208[rbp]
	mov	rdi, rax
	call	puts@PLT
	nop
.L11:
	mov	eax, DWORD PTR -4228[rbp]
	mov	edi, eax
	call	close@PLT
	cmp	eax, -1
	jne	.L5
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 4
	je	.L11
.L5:
	mov	rax, QWORD PTR -4224[rbp]
	mov	rdi, rax
	call	readdir@PLT
	mov	QWORD PTR -4216[rbp], rax
	cmp	QWORD PTR -4216[rbp], 0
	jne	.L12
	nop
.L14:
	mov	rax, QWORD PTR -4224[rbp]
	mov	rdi, rax
	call	closedir@PLT
	cmp	eax, -1
	jne	.L13
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 4
	je	.L14
.L13:
	mov	eax, 0
.L15:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	print, .-print
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.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, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"146973.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Failed to open directory\000"
	.align	2
.LC1:
	.ascii	"Failed to get current working directory\000"
	.align	2
.LC2:
	.ascii	"/\000"
	.align	2
.LC3:
	.ascii	".\000"
	.align	2
.LC4:
	.ascii	"..\000"
	.align	2
.LC5:
	.ascii	"%s\011\000"
	.align	2
.LC6:
	.ascii	"Failed to open file\000"
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	print
	.syntax unified
	.arm
	.fpu softvfp
	.type	print, %function
print:
	@ args = 0, pretend = 0, frame = 4192
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #4160
	sub	sp, sp, #36
	sub	r3, fp, #4096
	sub	r3, r3, #12
	str	r0, [r3, #-92]
	ldr	r3, .L18
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-92]
	bl	opendir
	str	r0, [r4, #-88]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #0
	bne	.L2
	ldr	r0, .L18+4
	bl	perror
	mov	r3, #1
	b	.L15
.L2:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, #4096
	mov	r0, r3
	bl	getcwd
	mov	r3, r0
	cmp	r3, #0
	bne	.L4
	ldr	r0, .L18+8
	bl	perror
	mov	r3, #1
	b	.L15
.L4:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, r2
	ldr	r2, .L18+12
	mov	r0, r3
	mov	r1, r2
	mov	r3, #2
	mov	r2, r3
	bl	memcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, [r2, #-92]
	mov	r0, r3
	bl	strcat
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, r2
	ldr	r2, .L18+12
	mov	r0, r3
	mov	r1, r2
	mov	r3, #2
	mov	r2, r3
	bl	memcpy
	b	.L5
.L12:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-84]
	add	r3, r3, #11
	ldr	r1, .L18+16
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L6
	b	.L5
.L6:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-84]
	add	r3, r3, #11
	ldr	r1, .L18+20
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L7
	b	.L5
.L7:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-84]
	add	r3, r3, #11
	mov	r1, r3
	ldr	r0, .L18+24
	bl	printf
	sub	r2, fp, #4096
	sub	r2, r2, #12
	sub	r2, r2, #4
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #56
	mov	r1, r2
	mov	r0, r3
	bl	strcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-84]
	add	r2, r3, #11
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #56
	mov	r1, r2
	mov	r0, r3
	bl	strcat
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #56
	mov	r1, #0
	mov	r0, r3
	bl	open
	str	r0, [r4, #-80]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-80]
	cmn	r3, #1
	bne	.L17
	ldr	r0, .L18+28
	bl	perror
	mov	r3, #1
	b	.L15
.L17:
	nop
.L10:
	sub	r3, fp, #4160
	sub	r3, r3, #12
	sub	r3, r3, #12
	sub	r2, fp, #4096
	sub	r2, r2, #12
	mov	r0, r2
	mov	r2, #20
	mov	r1, r3
	ldr	r0, [r0, #-80]
	bl	readline
	mov	r3, r0
	cmn	r3, #1
	bne	.L9
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #4
	beq	.L10
.L9:
	sub	r3, fp, #4160
	sub	r3, r3, #12
	sub	r3, r3, #12
	mov	r0, r3
	bl	puts
	nop
.L11:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-80]
	bl	close
	mov	r3, r0
	cmn	r3, #1
	bne	.L5
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #4
	beq	.L11
.L5:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-88]
	bl	readdir
	str	r0, [r4, #-84]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-84]
	cmp	r3, #0
	bne	.L12
	nop
.L14:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-88]
	bl	closedir
	mov	r3, r0
	cmn	r3, #1
	bne	.L13
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #4
	beq	.L14
.L13:
	mov	r3, #0
.L15:
	ldr	r2, .L18
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L16
	bl	__stack_chk_fail
.L16:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L19:
	.align	2
.L18:
	.word	.LC7
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.size	print, .-print
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
