	.file	"48576126.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"\033[0;31m"
	.text
	.globl	red
	.type	red, @function
red:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	red, .-red
	.globl	rederr
	.type	rederr, @function
rederr:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 7
	mov	esi, 1
	lea	rdi, .LC0[rip]
	call	fwrite@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	rederr, .-rederr
	.section	.rodata
.LC1:
	.string	"\033[0;32m"
	.text
	.globl	green
	.type	green, @function
green:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	green, .-green
	.section	.rodata
.LC2:
	.string	"\033[1;33m"
	.text
	.globl	yellow
	.type	yellow, @function
yellow:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	yellow, .-yellow
	.section	.rodata
.LC3:
	.string	"\033[0m"
	.text
	.globl	reset
	.type	reset, @function
reset:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	reset, .-reset
	.globl	reseterr
	.type	reseterr, @function
reseterr:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 4
	mov	esi, 1
	lea	rdi, .LC3[rip]
	call	fwrite@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	reseterr, .-reseterr
	.section	.rodata
.LC4:
	.string	"Error in sending file."
	.text
	.globl	sendFile
	.type	sendFile, @function
sendFile:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 2096
	mov	QWORD PTR -2088[rbp], rdi
	mov	DWORD PTR -2092[rbp], esi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -2064[rbp], 0
	mov	QWORD PTR -2056[rbp], 0
	lea	rdx, -2048[rbp]
	mov	eax, 0
	mov	ecx, 126
	mov	rdi, rdx
	rep stosq
	mov	QWORD PTR -1040[rbp], 0
	mov	QWORD PTR -1032[rbp], 0
	lea	rdx, -1024[rbp]
	mov	eax, 0
	mov	ecx, 126
	mov	rdi, rdx
	rep stosq
	mov	rdx, rdi
	mov	BYTE PTR [rdx], al
	add	rdx, 1
	jmp	.L8
.L11:
	mov	eax, DWORD PTR -2072[rbp]
	movsx	rdx, eax
	lea	rsi, -2064[rbp]
	mov	eax, DWORD PTR -2092[rbp]
	mov	ecx, 0
	mov	edi, eax
	call	send@PLT
	cmp	rax, -1
	jne	.L9
	mov	eax, 0
	call	rederr
	lea	rdi, .LC4[rip]
	call	perror@PLT
	mov	eax, 0
	call	reseterr
	mov	eax, 0
	jmp	.L12
.L9:
	lea	rsi, -1040[rbp]
	mov	eax, DWORD PTR -2092[rbp]
	mov	ecx, 0
	mov	edx, 1025
	mov	edi, eax
	call	recv@PLT
	mov	DWORD PTR -2068[rbp], eax
	lea	rax, -2064[rbp]
	mov	rsi, rax
	mov	eax, 0
	mov	edx, 128
	mov	rdi, rsi
	mov	rcx, rdx
	rep stosq
.L8:
	mov	rdx, QWORD PTR -2088[rbp]
	lea	rax, -2064[rbp]
	mov	rcx, rdx
	mov	edx, 1024
	mov	esi, 1
	mov	rdi, rax
	call	fread@PLT
	mov	DWORD PTR -2072[rbp], eax
	cmp	DWORD PTR -2072[rbp], 0
	jne	.L11
	mov	eax, 1
.L12:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	sendFile, .-sendFile
	.section	.rodata
.LC5:
	.string	"socket error"
.LC6:
	.string	"setsockopt"
	.align 8
.LC7:
	.string	"Server socket created successfully."
.LC8:
	.string	"bind failed"
.LC9:
	.string	"Binding successful."
.LC10:
	.string	"Listening for client...."
.LC11:
	.string	"Error in listening"
.LC12:
	.string	"accept"
.LC13:
	.string	"Connected to client\033[0m"
.LC14:
	.string	"Connection closed\033[0m"
	.align 8
.LC15:
	.string	"Requested file: \033[1;35m%s\033[0m\n"
.LC16:
	.string	"rb"
.LC17:
	.string	"Error in opening file"
.LC18:
	.string	"-1"
	.align 8
.LC19:
	.string	"File requested is not a regular file.\033[0m"
.LC20:
	.string	"-2"
.LC21:
	.string	"%lld"
	.align 8
.LC22:
	.string	"File data sent successfully.\033[0m"
	.align 8
.LC23:
	.string	"Some error occurred, could not send file.\033[0m"
	.text
	.globl	main
	.type	main, @function
main:
.LFB13:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 3424
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -3420[rbp], 1
	mov	QWORD PTR -3088[rbp], 0
	mov	QWORD PTR -3080[rbp], 0
	lea	rdx, -3072[rbp]
	mov	eax, 0
	mov	ecx, 126
	mov	rdi, rdx
	rep stosq
	mov	QWORD PTR -2064[rbp], 0
	mov	QWORD PTR -2056[rbp], 0
	lea	rdx, -2048[rbp]
	mov	eax, 0
	mov	ecx, 126
	mov	rdi, rdx
	rep stosq
	mov	QWORD PTR -1040[rbp], 0
	mov	QWORD PTR -1032[rbp], 0
	lea	rdx, -1024[rbp]
	mov	eax, 0
	mov	ecx, 126
	mov	rdi, rdx
	rep stosq
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -3412[rbp], eax
	cmp	DWORD PTR -3412[rbp], 0
	jns	.L15
	lea	rdi, .LC5[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L15:
	lea	rdx, -3420[rbp]
	mov	eax, DWORD PTR -3412[rbp]
	mov	r8d, 4
	mov	rcx, rdx
	mov	edx, 15
	mov	esi, 1
	mov	edi, eax
	call	setsockopt@PLT
	test	eax, eax
	je	.L16
	lea	rdi, .LC6[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L16:
	lea	rdi, .LC7[rip]
	call	puts@PLT
	mov	WORD PTR -3376[rbp], 2
	mov	DWORD PTR -3372[rbp], 0
	mov	edi, 8080
	call	htons@PLT
	mov	WORD PTR -3374[rbp], ax
	lea	rcx, -3376[rbp]
	mov	eax, DWORD PTR -3412[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	bind@PLT
	mov	DWORD PTR -3408[rbp], eax
	cmp	DWORD PTR -3408[rbp], 0
	jns	.L17
	lea	rdi, .LC8[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L17:
	lea	rdi, .LC9[rip]
	call	puts@PLT
.L22:
	mov	eax, DWORD PTR -3412[rbp]
	mov	esi, 3
	mov	edi, eax
	call	listen@PLT
	test	eax, eax
	jne	.L18
	lea	rdi, .LC10[rip]
	call	puts@PLT
	mov	DWORD PTR -3416[rbp], 16
	lea	rdx, -3416[rbp]
	lea	rcx, -3360[rbp]
	mov	eax, DWORD PTR -3412[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	accept@PLT
	mov	DWORD PTR -3404[rbp], eax
	cmp	DWORD PTR -3404[rbp], 0
	jns	.L20
	jmp	.L31
.L18:
	lea	rdi, .LC11[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L31:
	lea	rdi, .LC12[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L20:
	mov	eax, 0
	call	yellow
	lea	rdi, .LC13[rip]
	call	puts@PLT
	mov	eax, 0
	call	reset
.L29:
	lea	rsi, -3088[rbp]
	mov	eax, DWORD PTR -3404[rbp]
	mov	ecx, 0
	mov	edx, 1024
	mov	edi, eax
	call	recv@PLT
	mov	DWORD PTR -3400[rbp], eax
	movzx	eax, BYTE PTR -3088[rbp]
	movzx	eax, al
	test	eax, eax
	jne	.L21
	mov	eax, 0
	call	yellow
	lea	rdi, .LC14[rip]
	call	puts@PLT
	mov	eax, 0
	call	reset
	jmp	.L22
.L21:
	lea	rax, -3088[rbp]
	mov	rsi, rax
	lea	rdi, .LC15[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -3088[rbp]
	lea	rsi, .LC16[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -3392[rbp], rax
	cmp	QWORD PTR -3392[rbp], 0
	jne	.L23
	mov	eax, 0
	call	rederr
	lea	rdi, .LC17[rip]
	call	perror@PLT
	mov	eax, 0
	call	reseterr
	mov	eax, DWORD PTR -3404[rbp]
	mov	ecx, 0
	mov	edx, 2
	lea	rsi, .LC18[rip]
	mov	edi, eax
	call	send@PLT
	lea	rax, -3088[rbp]
	mov	rsi, rax
	mov	eax, 0
	mov	edx, 128
	mov	rdi, rsi
	mov	rcx, rdx
	rep stosq
	jmp	.L28
.L23:
	lea	rdx, -3344[rbp]
	lea	rax, -3088[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	stat@PLT
	mov	eax, DWORD PTR -3320[rbp]
	and	eax, 61440
	cmp	eax, 32768
	je	.L25
	mov	eax, 0
	call	red
	lea	rdi, .LC19[rip]
	call	puts@PLT
	mov	eax, 0
	call	reset
	mov	eax, DWORD PTR -3404[rbp]
	mov	ecx, 0
	mov	edx, 2
	lea	rsi, .LC20[rip]
	mov	edi, eax
	call	send@PLT
	lea	rax, -3088[rbp]
	mov	rsi, rax
	mov	eax, 0
	mov	edx, 128
	mov	rdi, rsi
	mov	rcx, rdx
	rep stosq
	jmp	.L28
.L25:
	mov	rax, QWORD PTR -3392[rbp]
	mov	edx, 2
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rax, QWORD PTR -3392[rbp]
	mov	rdi, rax
	call	ftell@PLT
	mov	QWORD PTR -3384[rbp], rax
	mov	rax, QWORD PTR -3392[rbp]
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rdx, QWORD PTR -3384[rbp]
	lea	rax, -3200[rbp]
	lea	rsi, .LC21[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -3200[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rsi, -3200[rbp]
	mov	eax, DWORD PTR -3404[rbp]
	mov	ecx, 0
	mov	edi, eax
	call	send@PLT
	lea	rsi, -2064[rbp]
	mov	eax, DWORD PTR -3404[rbp]
	mov	ecx, 0
	mov	edx, 1024
	mov	edi, eax
	call	recv@PLT
	mov	DWORD PTR -3396[rbp], eax
	mov	edx, DWORD PTR -3404[rbp]
	mov	rax, QWORD PTR -3392[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	sendFile
	test	eax, eax
	je	.L26
	mov	eax, 0
	call	green
	lea	rdi, .LC22[rip]
	call	puts@PLT
	jmp	.L27
.L26:
	mov	eax, 0
	call	red
	lea	rdi, .LC23[rip]
	call	puts@PLT
.L27:
	mov	eax, 0
	call	reset
	lea	rax, -3088[rbp]
	mov	rsi, rax
	mov	eax, 0
	mov	edx, 128
	mov	rdi, rsi
	mov	rcx, rdx
	rep stosq
.L28:
	jmp	.L29
	.cfi_endproc
.LFE13:
	.size	main, .-main
	.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	"48576126.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"\033[0;31m\000"
	.text
	.align	2
	.global	red
	.syntax unified
	.arm
	.fpu softvfp
	.type	red, %function
red:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L2
	bl	printf
	nop
	pop	{fp, pc}
.L3:
	.align	2
.L2:
	.word	.LC0
	.size	red, .-red
	.align	2
	.global	rederr
	.syntax unified
	.arm
	.fpu softvfp
	.type	rederr, %function
rederr:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r3, .L5
	ldr	r3, [r3]
	mov	r2, #7
	mov	r1, #1
	ldr	r0, .L5+4
	bl	fwrite
	nop
	pop	{fp, pc}
.L6:
	.align	2
.L5:
	.word	stderr
	.word	.LC0
	.size	rederr, .-rederr
	.section	.rodata
	.align	2
.LC1:
	.ascii	"\033[0;32m\000"
	.text
	.align	2
	.global	green
	.syntax unified
	.arm
	.fpu softvfp
	.type	green, %function
green:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L8
	bl	printf
	nop
	pop	{fp, pc}
.L9:
	.align	2
.L8:
	.word	.LC1
	.size	green, .-green
	.section	.rodata
	.align	2
.LC2:
	.ascii	"\033[1;33m\000"
	.text
	.align	2
	.global	yellow
	.syntax unified
	.arm
	.fpu softvfp
	.type	yellow, %function
yellow:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L11
	bl	printf
	nop
	pop	{fp, pc}
.L12:
	.align	2
.L11:
	.word	.LC2
	.size	yellow, .-yellow
	.section	.rodata
	.align	2
.LC3:
	.ascii	"\033[0m\000"
	.text
	.align	2
	.global	reset
	.syntax unified
	.arm
	.fpu softvfp
	.type	reset, %function
reset:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L14
	bl	printf
	nop
	pop	{fp, pc}
.L15:
	.align	2
.L14:
	.word	.LC3
	.size	reset, .-reset
	.align	2
	.global	reseterr
	.syntax unified
	.arm
	.fpu softvfp
	.type	reseterr, %function
reseterr:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r3, .L17
	ldr	r3, [r3]
	mov	r2, #4
	mov	r1, #1
	ldr	r0, .L17+4
	bl	fwrite
	nop
	pop	{fp, pc}
.L18:
	.align	2
.L17:
	.word	stderr
	.word	.LC3
	.size	reseterr, .-reseterr
	.section	.rodata
	.align	2
.LC4:
	.ascii	"Error in sending file.\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	sendFile
	.syntax unified
	.arm
	.fpu softvfp
	.type	sendFile, %function
sendFile:
	@ args = 0, pretend = 0, frame = 2072
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2064
	sub	sp, sp, #8
	str	r0, [fp, #-2072]
	str	r1, [fp, #-2076]
	ldr	r3, .L26
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-2060]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #1020
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #0
	str	r3, [fp, #-1036]
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, .L26+4
	mov	r1, #0
	mov	r0, r3
	bl	memset
	b	.L20
.L23:
	ldr	r2, [fp, #-2068]
	sub	r1, fp, #2048
	sub	r1, r1, #4
	sub	r1, r1, #8
	mov	r3, #0
	ldr	r0, [fp, #-2076]
	bl	send
	mov	r3, r0
	cmn	r3, #1
	bne	.L21
	bl	rederr
	ldr	r0, .L26+8
	bl	perror
	bl	reseterr
	mov	r3, #0
	b	.L24
.L21:
	sub	r1, fp, #1024
	sub	r1, r1, #4
	sub	r1, r1, #8
	mov	r3, #0
	ldr	r2, .L26+12
	ldr	r0, [fp, #-2076]
	bl	recv
	str	r0, [fp, #-2064]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #8
	mov	r0, r3
	mov	r3, #1024
	mov	r2, r3
	mov	r1, #0
	bl	memset
.L20:
	sub	r0, fp, #2048
	sub	r0, r0, #4
	sub	r0, r0, #8
	ldr	r3, [fp, #-2072]
	mov	r2, #1024
	mov	r1, #1
	bl	fread
	mov	r3, r0
	str	r3, [fp, #-2068]
	ldr	r3, [fp, #-2068]
	cmp	r3, #0
	bne	.L23
	mov	r3, #1
.L24:
	ldr	r2, .L26
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L25
	bl	__stack_chk_fail
.L25:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L27:
	.align	2
.L26:
	.word	.LC5
	.word	1021
	.word	.LC4
	.word	1025
	.size	sendFile, .-sendFile
	.section	.rodata
	.align	2
.LC6:
	.ascii	"socket error\000"
	.align	2
.LC7:
	.ascii	"setsockopt\000"
	.align	2
.LC8:
	.ascii	"Server socket created successfully.\000"
	.align	2
.LC9:
	.ascii	"bind failed\000"
	.align	2
.LC10:
	.ascii	"Binding successful.\000"
	.align	2
.LC11:
	.ascii	"Listening for client....\000"
	.align	2
.LC12:
	.ascii	"Error in listening\000"
	.align	2
.LC13:
	.ascii	"accept\000"
	.align	2
.LC14:
	.ascii	"Connected to client\033[0m\000"
	.align	2
.LC15:
	.ascii	"Connection closed\033[0m\000"
	.align	2
.LC16:
	.ascii	"Requested file: \033[1;35m%s\033[0m\012\000"
	.align	2
.LC17:
	.ascii	"rb\000"
	.align	2
.LC18:
	.ascii	"Error in opening file\000"
	.align	2
.LC19:
	.ascii	"-1\000"
	.align	2
.LC20:
	.ascii	"File requested is not a regular file.\033[0m\000"
	.align	2
.LC21:
	.ascii	"-2\000"
	.align	2
.LC22:
	.ascii	"%lld\000"
	.align	2
.LC23:
	.ascii	"File data sent successfully.\033[0m\000"
	.align	2
.LC24:
	.ascii	"Some error occurred, could not send file.\033[0m\000"
	.align	2
.LC25:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 3336
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #3344
	ldr	r3, .L46
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #1
	str	r3, [fp, #-3340]
	mov	r3, #0
	str	r3, [fp, #-3080]
	sub	r3, fp, #3072
	sub	r3, r3, #4
	mov	r2, #1020
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #0
	str	r3, [fp, #-2056]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	mov	r2, #1020
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #0
	str	r3, [fp, #-1032]
	sub	r3, fp, #1024
	sub	r3, r3, #4
	mov	r2, #1020
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-3332]
	ldr	r3, [fp, #-3332]
	cmp	r3, #0
	bge	.L29
	ldr	r0, .L46+4
	bl	perror
	mov	r0, #1
	bl	exit
.L29:
	sub	r3, fp, #3328
	sub	r3, r3, #4
	sub	r3, r3, #8
	mov	r2, #4
	str	r2, [sp]
	mov	r2, #15
	mov	r1, #1
	ldr	r0, [fp, #-3332]
	bl	setsockopt
	mov	r3, r0
	cmp	r3, #0
	beq	.L30
	ldr	r0, .L46+8
	bl	perror
	mov	r0, #1
	bl	exit
.L30:
	ldr	r0, .L46+12
	bl	puts
	sub	r3, fp, #4
	sub	r3, r3, #3200
	sub	r3, r3, #8
	mov	r2, #2
	strh	r2, [r3]	@ movhi
	mov	r3, #0
	str	r3, [fp, #-3208]
	ldr	r0, .L46+16
	bl	htons
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #4
	sub	r3, r3, #3200
	sub	r3, r3, #8
	strh	r2, [r3, #2]	@ movhi
	sub	r3, fp, #3200
	sub	r3, r3, #4
	sub	r3, r3, #8
	mov	r2, #16
	mov	r1, r3
	ldr	r0, [fp, #-3332]
	bl	bind
	str	r0, [fp, #-3328]
	ldr	r3, [fp, #-3328]
	cmp	r3, #0
	bge	.L31
	ldr	r0, .L46+20
	bl	perror
	mov	r0, #1
	bl	exit
.L31:
	ldr	r0, .L46+24
	bl	puts
.L36:
	mov	r1, #3
	ldr	r0, [fp, #-3332]
	bl	listen
	mov	r3, r0
	cmp	r3, #0
	bne	.L32
	ldr	r0, .L46+28
	bl	puts
	mov	r3, #16
	str	r3, [fp, #-3336]
	sub	r2, fp, #3328
	sub	r2, r2, #4
	sub	r2, r2, #4
	sub	r3, fp, #3184
	sub	r3, r3, #4
	sub	r3, r3, #8
	mov	r1, r3
	ldr	r0, [fp, #-3332]
	bl	accept
	str	r0, [fp, #-3324]
	ldr	r3, [fp, #-3324]
	cmp	r3, #0
	bge	.L34
	b	.L45
.L32:
	ldr	r0, .L46+32
	bl	perror
	mov	r0, #1
	bl	exit
.L45:
	ldr	r0, .L46+36
	bl	perror
	mov	r0, #1
	bl	exit
.L34:
	bl	yellow
	ldr	r0, .L46+40
	bl	puts
	bl	reset
.L43:
	sub	r1, fp, #3072
	sub	r1, r1, #4
	sub	r1, r1, #4
	mov	r3, #0
	mov	r2, #1024
	ldr	r0, [fp, #-3324]
	bl	recv
	str	r0, [fp, #-3320]
	ldrb	r3, [fp, #-3080]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L35
	bl	yellow
	ldr	r0, .L46+44
	bl	puts
	bl	reset
	b	.L36
.L35:
	sub	r3, fp, #3072
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L46+48
	bl	printf
	sub	r3, fp, #3072
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r1, .L46+52
	mov	r0, r3
	bl	fopen
	str	r0, [fp, #-3316]
	ldr	r3, [fp, #-3316]
	cmp	r3, #0
	bne	.L37
	bl	rederr
	ldr	r0, .L46+56
	bl	perror
	bl	reseterr
	mov	r3, #0
	mov	r2, #2
	ldr	r1, .L46+60
	ldr	r0, [fp, #-3324]
	bl	send
	sub	r3, fp, #3072
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	mov	r3, #1024
	mov	r2, r3
	mov	r1, #0
	bl	memset
	b	.L42
.L37:
	sub	r2, fp, #3296
	sub	r2, r2, #4
	sub	r3, fp, #3072
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	stat
	ldr	r3, [fp, #-3284]
	and	r3, r3, #61440
	cmp	r3, #32768
	beq	.L39
	bl	red
	ldr	r0, .L46+64
	bl	puts
	bl	reset
	mov	r3, #0
	mov	r2, #2
	ldr	r1, .L46+68
	ldr	r0, [fp, #-3324]
	bl	send
	sub	r3, fp, #3072
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	mov	r3, #1024
	mov	r2, r3
	mov	r1, #0
	bl	memset
	b	.L42
.L39:
	mov	r2, #2
	mov	r1, #0
	ldr	r0, [fp, #-3316]
	bl	fseek
	ldr	r0, [fp, #-3316]
	bl	ftell
	mov	r3, r0
	mov	r2, r3
	asr	r3, r2, #31
	str	r2, [fp, #-3308]
	str	r3, [fp, #-3304]
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-3316]
	bl	fseek
	sub	r0, fp, #3168
	sub	r0, r0, #4
	sub	r0, r0, #8
	ldr	r2, [fp, #-3308]
	ldr	r3, [fp, #-3304]
	ldr	r1, .L46+72
	bl	sprintf
	sub	r3, fp, #3168
	sub	r3, r3, #4
	sub	r3, r3, #8
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r1, fp, #3168
	sub	r1, r1, #4
	sub	r1, r1, #8
	mov	r3, #0
	ldr	r0, [fp, #-3324]
	bl	send
	sub	r1, fp, #2048
	sub	r1, r1, #4
	sub	r1, r1, #4
	mov	r3, #0
	mov	r2, #1024
	ldr	r0, [fp, #-3324]
	bl	recv
	str	r0, [fp, #-3312]
	ldr	r1, [fp, #-3324]
	ldr	r0, [fp, #-3316]
	bl	sendFile
	mov	r3, r0
	cmp	r3, #0
	beq	.L40
	bl	green
	ldr	r0, .L46+76
	bl	puts
	b	.L41
.L40:
	bl	red
	ldr	r0, .L46+80
	bl	puts
.L41:
	bl	reset
	sub	r3, fp, #3072
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	mov	r3, #1024
	mov	r2, r3
	mov	r1, #0
	bl	memset
.L42:
	b	.L43
.L47:
	.align	2
.L46:
	.word	.LC25
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	8080
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.word	.LC16
	.word	.LC17
	.word	.LC18
	.word	.LC19
	.word	.LC20
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.word	.LC24
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
