	.file	"314892.c"
	.intel_syntax noprefix
	.text
	.globl	quit
	.bss
	.align 4
	.type	quit, @object
	.size	quit, 4
quit:
	.zero	4
	.globl	child_to_wait_for
	.align 4
	.type	child_to_wait_for, @object
	.size	child_to_wait_for, 4
child_to_wait_for:
	.zero	4
	.section	.rodata
.LC0:
	.string	"handle_signal_chld(%d)\n"
	.text
	.globl	handle_signal_chld
	.type	handle_signal_chld, @function
handle_signal_chld:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR child_to_wait_for[rip]
	add	eax, 1
	mov	DWORD PTR child_to_wait_for[rip], eax
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	handle_signal_chld, .-handle_signal_chld
	.section	.rodata
	.align 8
.LC1:
	.string	"%04d_ABCDEFGHIJKL_This_line_is_64_bytes_long_ABCDEFGHIJKL_%04d\r\n"
	.align 8
.LC2:
	.string	"snprintf() returned %d in build_content()\n"
	.text
	.globl	build_content
	.type	build_content, @function
build_content:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	add	rsp, -128
	mov	QWORD PTR -120[rbp], rdi
	mov	DWORD PTR -124[rbp], esi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -104[rbp], 0
	jmp	.L3
.L6:
	mov	ecx, DWORD PTR -104[rbp]
	mov	edx, DWORD PTR -104[rbp]
	lea	rax, -96[rbp]
	mov	r8d, ecx
	mov	ecx, edx
	lea	rdx, .LC1[rip]
	mov	esi, 80
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	mov	DWORD PTR -100[rbp], eax
	cmp	DWORD PTR -100[rbp], 64
	je	.L4
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, DWORD PTR -100[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
.L4:
	add	DWORD PTR -104[rbp], 1
	cmp	DWORD PTR -124[rbp], 63
	jle	.L5
	lea	rcx, -96[rbp]
	mov	rax, QWORD PTR -120[rbp]
	mov	edx, 64
	mov	rsi, rcx
	mov	rdi, rax
	call	memcpy@PLT
	add	QWORD PTR -120[rbp], 64
	sub	DWORD PTR -124[rbp], 64
	jmp	.L3
.L5:
	mov	eax, DWORD PTR -124[rbp]
	movsx	rdx, eax
	lea	rcx, -96[rbp]
	mov	rax, QWORD PTR -120[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	memcpy@PLT
	mov	eax, DWORD PTR -124[rbp]
	cdqe
	add	QWORD PTR -120[rbp], rax
	mov	DWORD PTR -124[rbp], 0
.L3:
	cmp	DWORD PTR -124[rbp], 0
	jg	.L6
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L7
	call	__stack_chk_fail@PLT
.L7:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	build_content, .-build_content
	.globl	build_crap
	.type	build_crap, @function
build_crap:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	jmp	.L9
.L11:
	mov	DWORD PTR -4[rbp], 8
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -28[rbp]
	jle	.L10
	mov	eax, DWORD PTR -28[rbp]
	mov	DWORD PTR -4[rbp], eax
.L10:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, crap.0[rip]
	mov	rdi, rax
	call	memcpy@PLT
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	add	QWORD PTR -24[rbp], rax
	mov	eax, DWORD PTR -4[rbp]
	sub	DWORD PTR -28[rbp], eax
.L9:
	cmp	DWORD PTR -28[rbp], 0
	jg	.L11
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	build_crap, .-build_crap
	.section	.rodata
	.align 8
.LC3:
	.string	"HTTP/1.1 200 OK\r\nContent-Type: text/plain\r\nTransfer-Encoding: chunked\r\n\r\n"
.LC4:
	.string	"%x\r\n"
.LC5:
	.string	"0\r\n"
	.align 8
.LC6:
	.string	"resp_length=%d buffer_length=%d content_length=%d\n"
	.text
	.globl	build_chunked_response
	.type	build_chunked_response, @function
build_chunked_response:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 48
	mov	DWORD PTR -36[rbp], edi
	mov	QWORD PTR -48[rbp], rsi
	mov	eax, DWORD PTR -36[rbp]
	lea	edx, 256[rax]
	mov	eax, DWORD PTR -36[rbp]
	sar	eax, 4
	add	eax, edx
	mov	DWORD PTR -20[rbp], eax
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -16[rbp], rax
	mov	eax, DWORD PTR -20[rbp]
	movsx	rcx, eax
	mov	rax, QWORD PTR -16[rbp]
	lea	rdx, .LC3[rip]
	mov	rsi, rcx
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	mov	rdx, QWORD PTR -48[rbp]
	mov	DWORD PTR [rdx], eax
	mov	eax, DWORD PTR -36[rbp]
	cdqe
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	edx, DWORD PTR -36[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	build_content
	mov	DWORD PTR -28[rbp], 0
	jmp	.L13
.L15:
	call	rand@PLT
	movsx	rdx, eax
	imul	rdx, rdx, 1381296015
	shr	rdx, 32
	sar	edx, 6
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	imul	ecx, edx, 199
	sub	eax, ecx
	mov	edx, eax
	lea	eax, 1[rdx]
	mov	DWORD PTR -24[rbp], eax
	mov	edx, DWORD PTR -28[rbp]
	mov	eax, DWORD PTR -24[rbp]
	add	eax, edx
	cmp	DWORD PTR -36[rbp], eax
	jge	.L14
	mov	eax, DWORD PTR -36[rbp]
	sub	eax, DWORD PTR -28[rbp]
	mov	DWORD PTR -24[rbp], eax
.L14:
	mov	rax, QWORD PTR -48[rbp]
	mov	edx, DWORD PTR [rax]
	mov	eax, DWORD PTR -20[rbp]
	sub	eax, edx
	cdqe
	mov	rdx, QWORD PTR -48[rbp]
	mov	edx, DWORD PTR [rdx]
	movsx	rcx, edx
	mov	rdx, QWORD PTR -16[rbp]
	lea	rdi, [rcx+rdx]
	mov	edx, DWORD PTR -24[rbp]
	mov	ecx, edx
	lea	rdx, .LC4[rip]
	mov	rsi, rax
	mov	eax, 0
	call	snprintf@PLT
	mov	edx, eax
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR [rax]
	add	edx, eax
	mov	rax, QWORD PTR -48[rbp]
	mov	DWORD PTR [rax], edx
	mov	eax, DWORD PTR -24[rbp]
	cdqe
	mov	edx, DWORD PTR -28[rbp]
	movsx	rcx, edx
	mov	rdx, QWORD PTR -8[rbp]
	lea	rsi, [rcx+rdx]
	mov	rdx, QWORD PTR -48[rbp]
	mov	edx, DWORD PTR [rdx]
	movsx	rcx, edx
	mov	rdx, QWORD PTR -16[rbp]
	add	rcx, rdx
	mov	rdx, rax
	mov	rdi, rcx
	call	memcpy@PLT
	mov	rax, QWORD PTR -48[rbp]
	mov	edx, DWORD PTR [rax]
	mov	eax, DWORD PTR -24[rbp]
	add	edx, eax
	mov	rax, QWORD PTR -48[rbp]
	mov	DWORD PTR [rax], edx
	mov	eax, DWORD PTR -24[rbp]
	add	DWORD PTR -28[rbp], eax
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR [rax]
	lea	ecx, 1[rax]
	mov	rdx, QWORD PTR -48[rbp]
	mov	DWORD PTR [rdx], ecx
	movsx	rdx, eax
	mov	rax, QWORD PTR -16[rbp]
	add	rax, rdx
	mov	BYTE PTR [rax], 13
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR [rax]
	lea	ecx, 1[rax]
	mov	rdx, QWORD PTR -48[rbp]
	mov	DWORD PTR [rdx], ecx
	movsx	rdx, eax
	mov	rax, QWORD PTR -16[rbp]
	add	rax, rdx
	mov	BYTE PTR [rax], 10
.L13:
	mov	eax, DWORD PTR -28[rbp]
	cmp	eax, DWORD PTR -36[rbp]
	jl	.L15
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR [rax]
	movsx	rdx, eax
	mov	rax, QWORD PTR -16[rbp]
	add	rax, rdx
	mov	edx, 3
	lea	rsi, .LC5[rip]
	mov	rdi, rax
	call	memcpy@PLT
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR [rax]
	lea	edx, 3[rax]
	mov	rax, QWORD PTR -48[rbp]
	mov	DWORD PTR [rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR [rax]
	mov	ecx, DWORD PTR -36[rbp]
	mov	edx, DWORD PTR -20[rbp]
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -16[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	build_chunked_response, .-build_chunked_response
	.globl	modes_array
	.section	.rodata
.LC7:
	.string	"chunked"
.LC8:
	.string	"addcrap"
.LC9:
	.string	"normal"
	.section	.data.rel.ro.local,"aw"
	.align 32
	.type	modes_array, @object
	.size	modes_array, 64
modes_array:
	.long	1
	.zero	4
	.quad	.LC7
	.long	2
	.zero	4
	.quad	.LC8
	.long	3
	.zero	4
	.quad	.LC9
	.long	0
	.zero	4
	.quad	0
	.section	.rodata
.LC10:
	.string	"write"
	.text
	.globl	send_response
	.type	send_response, @function
send_response:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -24[rbp], edx
	jmp	.L18
.L22:
	call	rand@PLT
	movsx	rdx, eax
	imul	rdx, rdx, -1518422781
	shr	rdx, 32
	add	edx, eax
	sar	edx, 6
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	imul	ecx, edx, 99
	sub	eax, ecx
	mov	edx, eax
	lea	eax, 1[rdx]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -24[rbp]
	jle	.L19
	mov	eax, DWORD PTR -24[rbp]
	mov	DWORD PTR -4[rbp], eax
.L19:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rcx, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR -20[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	jns	.L20
	lea	rdi, .LC10[rip]
	call	perror@PLT
	jmp	.L17
.L20:
	mov	eax, DWORD PTR -4[rbp]
	sub	DWORD PTR -24[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	add	QWORD PTR -32[rbp], rax
	mov	edi, 10000
	call	usleep@PLT
.L18:
	cmp	DWORD PTR -24[rbp], 0
	jg	.L22
.L17:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	send_response, .-send_response
	.section	.rodata
.LC11:
	.string	"read"
.LC12:
	.string	"\r\n\r\n"
.LC13:
	.string	"headers :\n%.*s"
.LC14:
	.string	"Method = %s, URI = %s, %s\n"
.LC15:
	.string	"GET"
	.align 8
.LC16:
	.string	"HTTP/1.1 200 OK\r\nServer: minihttptestserver\r\nContent-Type: text/plain\r\nContent-Length: %d\r\n\r\n"
	.align 8
.LC17:
	.string	"HTTP/1.1 200 OK\r\nServer: minihttptestserver\r\nContent-Type: text/plain\r\n\r\n"
	.text
	.globl	handle_http_connection
	.type	handle_http_connection, @function
handle_http_connection:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 2480
	mov	DWORD PTR -2468[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -2448[rbp], 0
	mov	DWORD PTR -2444[rbp], 0
	mov	DWORD PTR -2428[rbp], 16384
	jmp	.L24
.L32:
	mov	eax, DWORD PTR -2448[rbp]
	cdqe
	mov	edx, 2048
	sub	rdx, rax
	mov	eax, DWORD PTR -2448[rbp]
	cdqe
	lea	rcx, -2064[rbp]
	add	rcx, rax
	mov	eax, DWORD PTR -2468[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -2440[rbp], eax
	cmp	DWORD PTR -2440[rbp], 0
	jns	.L25
	lea	rdi, .LC11[rip]
	call	perror@PLT
	jmp	.L23
.L25:
	cmp	DWORD PTR -2440[rbp], 0
	je	.L64
	mov	eax, DWORD PTR -2440[rbp]
	add	DWORD PTR -2448[rbp], eax
	mov	DWORD PTR -2436[rbp], 0
	jmp	.L29
.L31:
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	lea	rdx, -2064[rbp]
	add	rax, rdx
	mov	edx, 4
	lea	rsi, .LC12[rip]
	mov	rdi, rax
	call	memcmp@PLT
	test	eax, eax
	jne	.L30
	mov	DWORD PTR -2444[rbp], 1
	jmp	.L24
.L30:
	add	DWORD PTR -2436[rbp], 1
.L29:
	mov	eax, DWORD PTR -2448[rbp]
	sub	eax, 3
	cmp	DWORD PTR -2436[rbp], eax
	jl	.L31
.L24:
	cmp	DWORD PTR -2448[rbp], 2047
	jg	.L28
	cmp	DWORD PTR -2444[rbp], 0
	je	.L32
	jmp	.L28
.L64:
	nop
.L28:
	cmp	DWORD PTR -2444[rbp], 0
	je	.L65
	lea	rdx, -2064[rbp]
	mov	eax, DWORD PTR -2448[rbp]
	mov	esi, eax
	lea	rdi, .LC13[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -2064[rbp]
	mov	QWORD PTR -2424[rbp], rax
	mov	DWORD PTR -2436[rbp], 0
	jmp	.L34
.L36:
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L35
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 13
	je	.L35
	mov	rax, QWORD PTR -2424[rbp]
	movzx	edx, BYTE PTR [rax]
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	mov	BYTE PTR -2400[rbp+rax], dl
	add	QWORD PTR -2424[rbp], 1
	add	DWORD PTR -2436[rbp], 1
.L34:
	cmp	DWORD PTR -2436[rbp], 14
	jle	.L36
.L35:
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	mov	BYTE PTR -2400[rbp+rax], 0
	jmp	.L37
.L38:
	add	QWORD PTR -2424[rbp], 1
.L37:
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L38
	mov	DWORD PTR -2436[rbp], 0
	jmp	.L39
.L41:
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L40
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 13
	je	.L40
	mov	rax, QWORD PTR -2424[rbp]
	movzx	edx, BYTE PTR [rax]
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	mov	BYTE PTR -2320[rbp+rax], dl
	add	QWORD PTR -2424[rbp], 1
	add	DWORD PTR -2436[rbp], 1
.L39:
	cmp	DWORD PTR -2436[rbp], 254
	jle	.L41
.L40:
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	mov	BYTE PTR -2320[rbp+rax], 0
	jmp	.L42
.L43:
	add	QWORD PTR -2424[rbp], 1
.L42:
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L43
	mov	DWORD PTR -2436[rbp], 0
	jmp	.L44
.L46:
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L45
	mov	rax, QWORD PTR -2424[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 13
	je	.L45
	mov	rax, QWORD PTR -2424[rbp]
	movzx	edx, BYTE PTR [rax]
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	mov	BYTE PTR -2384[rbp+rax], dl
	add	QWORD PTR -2424[rbp], 1
	add	DWORD PTR -2436[rbp], 1
.L44:
	cmp	DWORD PTR -2436[rbp], 14
	jle	.L46
.L45:
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	mov	BYTE PTR -2384[rbp+rax], 0
	lea	rcx, -2384[rbp]
	lea	rdx, -2320[rbp]
	lea	rax, -2400[rbp]
	mov	rsi, rax
	lea	rdi, .LC14[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -2400[rbp]
	lea	rsi, .LC15[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	je	.L47
	movabs	rax, 3543824036068086856
	movabs	rdx, 8387194681774060576
	mov	QWORD PTR -2368[rbp], rax
	mov	QWORD PTR -2360[rbp], rdx
	movabs	rax, 2338616487853715304
	movabs	rdx, 965007783809018945
	mov	QWORD PTR -2352[rbp], rax
	mov	QWORD PTR -2344[rbp], rdx
	movabs	rax, 2322299878307021066
	movabs	rdx, 2829086591567175
	mov	QWORD PTR -2336[rbp], rax
	mov	QWORD PTR -2328[rbp], rdx
	mov	DWORD PTR -2440[rbp], 47
	lea	rax, -2368[rbp]
	mov	QWORD PTR -2408[rbp], rax
	jmp	.L48
.L51:
	mov	eax, DWORD PTR -2440[rbp]
	movsx	rdx, eax
	mov	rcx, QWORD PTR -2408[rbp]
	mov	eax, DWORD PTR -2468[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	DWORD PTR -2436[rbp], eax
	cmp	DWORD PTR -2436[rbp], 0
	jns	.L49
	lea	rdi, .LC10[rip]
	call	perror@PLT
	jmp	.L23
.L49:
	mov	eax, DWORD PTR -2436[rbp]
	sub	DWORD PTR -2440[rbp], eax
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	add	QWORD PTR -2408[rbp], rax
.L48:
	cmp	DWORD PTR -2440[rbp], 0
	jg	.L51
	jmp	.L23
.L47:
	mov	DWORD PTR -2432[rbp], 0
	mov	DWORD PTR -2436[rbp], 0
	jmp	.L52
.L55:
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	sal	rax, 4
	mov	rdx, rax
	lea	rax, modes_array[rip+8]
	mov	rdx, QWORD PTR [rdx+rax]
	lea	rax, -2320[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strstr@PLT
	test	rax, rax
	je	.L53
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	sal	rax, 4
	mov	rdx, rax
	lea	rax, modes_array[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -2432[rbp], eax
	jmp	.L54
.L53:
	add	DWORD PTR -2436[rbp], 1
.L52:
	mov	eax, DWORD PTR -2436[rbp]
	cdqe
	sal	rax, 4
	mov	rdx, rax
	lea	rax, modes_array[rip]
	mov	eax, DWORD PTR [rdx+rax]
	test	eax, eax
	jne	.L55
.L54:
	cmp	DWORD PTR -2432[rbp], 1
	je	.L56
	cmp	DWORD PTR -2432[rbp], 2
	je	.L57
	jmp	.L63
.L56:
	lea	rdx, -2452[rbp]
	mov	eax, DWORD PTR -2428[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	build_chunked_response
	mov	QWORD PTR -2416[rbp], rax
	jmp	.L59
.L57:
	mov	eax, DWORD PTR -2428[rbp]
	add	eax, 256
	mov	DWORD PTR -2452[rbp], eax
	mov	eax, DWORD PTR -2452[rbp]
	cdqe
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -2416[rbp], rax
	mov	eax, DWORD PTR -2452[rbp]
	movsx	rsi, eax
	mov	edx, DWORD PTR -2428[rbp]
	mov	rax, QWORD PTR -2416[rbp]
	mov	ecx, edx
	lea	rdx, .LC16[rip]
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	mov	DWORD PTR -2440[rbp], eax
	mov	edx, DWORD PTR -2428[rbp]
	mov	eax, DWORD PTR -2440[rbp]
	add	eax, edx
	add	eax, 2048
	mov	DWORD PTR -2452[rbp], eax
	mov	eax, DWORD PTR -2452[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -2416[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	realloc@PLT
	mov	QWORD PTR -2416[rbp], rax
	mov	eax, DWORD PTR -2440[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -2416[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -2428[rbp]
	mov	esi, eax
	mov	rdi, rdx
	call	build_content
	mov	eax, DWORD PTR -2440[rbp]
	movsx	rdx, eax
	mov	eax, DWORD PTR -2428[rbp]
	cdqe
	add	rdx, rax
	mov	rax, QWORD PTR -2416[rbp]
	add	rax, rdx
	mov	esi, 2048
	mov	rdi, rax
	call	build_crap
	jmp	.L59
.L63:
	mov	eax, DWORD PTR -2428[rbp]
	add	eax, 256
	mov	DWORD PTR -2452[rbp], eax
	mov	eax, DWORD PTR -2452[rbp]
	cdqe
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -2416[rbp], rax
	mov	eax, DWORD PTR -2452[rbp]
	movsx	rcx, eax
	mov	rax, QWORD PTR -2416[rbp]
	lea	rdx, .LC17[rip]
	mov	rsi, rcx
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	mov	DWORD PTR -2440[rbp], eax
	mov	edx, DWORD PTR -2428[rbp]
	mov	eax, DWORD PTR -2440[rbp]
	add	eax, edx
	mov	DWORD PTR -2452[rbp], eax
	mov	eax, DWORD PTR -2452[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -2416[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	realloc@PLT
	mov	QWORD PTR -2416[rbp], rax
	mov	eax, DWORD PTR -2452[rbp]
	sub	eax, DWORD PTR -2440[rbp]
	mov	edx, DWORD PTR -2440[rbp]
	movsx	rcx, edx
	mov	rdx, QWORD PTR -2416[rbp]
	add	rdx, rcx
	mov	esi, eax
	mov	rdi, rdx
	call	build_content
.L59:
	cmp	QWORD PTR -2416[rbp], 0
	je	.L23
	mov	edx, DWORD PTR -2452[rbp]
	mov	rcx, QWORD PTR -2416[rbp]
	mov	eax, DWORD PTR -2468[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	send_response
	mov	rax, QWORD PTR -2416[rbp]
	mov	rdi, rax
	call	free@PLT
	jmp	.L23
.L65:
	nop
.L23:
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L62
	call	__stack_chk_fail@PLT
.L62:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	handle_http_connection, .-handle_http_connection
	.section	.rodata
	.align 8
.LC18:
	.string	"unknown command line switch '%s'\n"
	.align 8
.LC19:
	.string	"unkown command line argument '%s'\n"
.LC20:
	.string	"socket"
.LC21:
	.string	"bind"
.LC22:
	.string	"listen"
.LC23:
	.string	"getsockname"
.LC24:
	.string	"Listening on port %hu\n"
.LC25:
	.string	"wb"
	.align 8
.LC26:
	.string	"error writing to file %s : %dbytes written (out of %d)\n"
	.align 8
.LC27:
	.string	"error opening file %s for writing\n"
.LC28:
	.string	"wait"
	.align 8
.LC29:
	.string	"child(%d) terminated with status %d\n"
.LC30:
	.string	"accept"
.LC31:
	.string	"accept..."
.LC32:
	.string	"fork"
.LC33:
	.string	"Bye..."
	.text
	.globl	main
	.type	main, @function
main:
.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, 384
	mov	DWORD PTR -372[rbp], edi
	mov	QWORD PTR -384[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -352[rbp], 0
	mov	WORD PTR -366[rbp], 0
	mov	DWORD PTR -340[rbp], 0
	mov	QWORD PTR -328[rbp], 0
	mov	DWORD PTR -344[rbp], 1
	jmp	.L67
.L76:
	mov	eax, DWORD PTR -344[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -384[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 45
	jne	.L68
	mov	eax, DWORD PTR -344[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -384[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	add	rax, 1
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	cmp	eax, 112
	je	.L69
	cmp	eax, 112
	jg	.L70
	cmp	eax, 54
	je	.L71
	cmp	eax, 101
	je	.L72
	jmp	.L70
.L71:
	mov	DWORD PTR -352[rbp], 1
	jmp	.L75
.L72:
	add	DWORD PTR -344[rbp], 1
	mov	eax, DWORD PTR -344[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -384[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR -328[rbp], rax
	jmp	.L75
.L69:
	add	DWORD PTR -344[rbp], 1
	mov	eax, DWORD PTR -344[rbp]
	cmp	eax, DWORD PTR -372[rbp]
	jge	.L112
	mov	eax, DWORD PTR -344[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -384[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	WORD PTR -366[rbp], ax
	jmp	.L112
.L70:
	mov	eax, DWORD PTR -344[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -384[rbp]
	add	rax, rdx
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC18[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L75
.L68:
	mov	eax, DWORD PTR -344[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -384[rbp]
	add	rax, rdx
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC19[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L75
.L112:
	nop
.L75:
	add	DWORD PTR -344[rbp], 1
.L67:
	mov	eax, DWORD PTR -344[rbp]
	cmp	eax, DWORD PTR -372[rbp]
	jl	.L76
	mov	edi, 0
	call	time@PLT
	mov	edi, eax
	call	srand@PLT
	lea	rsi, handle_signal_chld[rip]
	mov	edi, 17
	call	signal@PLT
	cmp	DWORD PTR -352[rbp], 0
	je	.L77
	mov	eax, 10
	jmp	.L78
.L77:
	mov	eax, 2
.L78:
	mov	edx, 0
	mov	esi, 1
	mov	edi, eax
	call	socket@PLT
	mov	DWORD PTR -348[rbp], eax
	cmp	DWORD PTR -348[rbp], 0
	jns	.L79
	lea	rdi, .LC20[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L110
.L79:
	lea	rax, -272[rbp]
	mov	edx, 128
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	lea	rax, -144[rbp]
	mov	edx, 128
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	cmp	DWORD PTR -352[rbp], 0
	je	.L81
	lea	rax, -272[rbp]
	mov	QWORD PTR -312[rbp], rax
	mov	rax, QWORD PTR -312[rbp]
	mov	WORD PTR [rax], 10
	movzx	eax, WORD PTR -366[rbp]
	mov	edi, eax
	call	htons@PLT
	mov	rdx, QWORD PTR -312[rbp]
	mov	WORD PTR 2[rdx], ax
	mov	rcx, QWORD PTR -312[rbp]
	mov	rax, QWORD PTR in6addr_loopback[rip]
	mov	rdx, QWORD PTR in6addr_loopback[rip+8]
	mov	QWORD PTR 8[rcx], rax
	mov	QWORD PTR 16[rcx], rdx
	jmp	.L82
.L81:
	lea	rax, -272[rbp]
	mov	QWORD PTR -320[rbp], rax
	mov	rax, QWORD PTR -320[rbp]
	mov	WORD PTR [rax], 2
	movzx	eax, WORD PTR -366[rbp]
	mov	edi, eax
	call	htons@PLT
	mov	rdx, QWORD PTR -320[rbp]
	mov	WORD PTR 2[rdx], ax
	mov	edi, 2130706433
	call	htonl@PLT
	mov	rdx, QWORD PTR -320[rbp]
	mov	DWORD PTR 4[rdx], eax
.L82:
	cmp	DWORD PTR -352[rbp], 0
	je	.L83
	mov	edx, 28
	jmp	.L84
.L83:
	mov	edx, 16
.L84:
	lea	rcx, -272[rbp]
	mov	eax, DWORD PTR -348[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	bind@PLT
	test	eax, eax
	jns	.L85
	lea	rdi, .LC21[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L110
.L85:
	mov	eax, DWORD PTR -348[rbp]
	mov	esi, 5
	mov	edi, eax
	call	listen@PLT
	test	eax, eax
	jns	.L86
	lea	rdi, .LC22[rip]
	call	perror@PLT
.L86:
	cmp	WORD PTR -366[rbp], 0
	jne	.L87
	mov	DWORD PTR -364[rbp], 128
	lea	rdx, -364[rbp]
	lea	rcx, -272[rbp]
	mov	eax, DWORD PTR -348[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	getsockname@PLT
	test	eax, eax
	jns	.L88
	lea	rdi, .LC23[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L110
.L88:
	cmp	DWORD PTR -352[rbp], 0
	je	.L89
	lea	rax, -272[rbp]
	mov	QWORD PTR -296[rbp], rax
	mov	rax, QWORD PTR -296[rbp]
	movzx	eax, WORD PTR 2[rax]
	movzx	eax, ax
	mov	edi, eax
	call	ntohs@PLT
	mov	WORD PTR -366[rbp], ax
	jmp	.L90
.L89:
	lea	rax, -272[rbp]
	mov	QWORD PTR -304[rbp], rax
	mov	rax, QWORD PTR -304[rbp]
	movzx	eax, WORD PTR 2[rax]
	movzx	eax, ax
	mov	edi, eax
	call	ntohs@PLT
	mov	WORD PTR -366[rbp], ax
.L90:
	movzx	eax, WORD PTR -366[rbp]
	mov	esi, eax
	lea	rdi, .LC24[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
.L87:
	cmp	QWORD PTR -328[rbp], 0
	je	.L94
	mov	rax, QWORD PTR -328[rbp]
	lea	rsi, .LC25[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -288[rbp], rax
	cmp	QWORD PTR -288[rbp], 0
	je	.L92
	mov	edi, 16384
	call	malloc@PLT
	mov	QWORD PTR -280[rbp], rax
	mov	rax, QWORD PTR -280[rbp]
	mov	esi, 16384
	mov	rdi, rax
	call	build_content
	mov	rdx, QWORD PTR -288[rbp]
	mov	rax, QWORD PTR -280[rbp]
	mov	rcx, rdx
	mov	edx, 16384
	mov	esi, 1
	mov	rdi, rax
	call	fwrite@PLT
	mov	DWORD PTR -344[rbp], eax
	cmp	DWORD PTR -344[rbp], 16384
	je	.L93
	mov	rax, QWORD PTR stderr[rip]
	mov	ecx, DWORD PTR -344[rbp]
	mov	rdx, QWORD PTR -328[rbp]
	mov	r8d, 16384
	lea	rsi, .LC26[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
.L93:
	mov	rax, QWORD PTR -280[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -288[rbp]
	mov	rdi, rax
	call	fclose@PLT
	jmp	.L94
.L92:
	mov	rax, QWORD PTR stderr[rip]
	mov	rdx, QWORD PTR -328[rbp]
	lea	rsi, .LC27[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L94
.L98:
	lea	rax, -356[rbp]
	mov	rdi, rax
	call	wait@PLT
	mov	DWORD PTR -332[rbp], eax
	cmp	DWORD PTR -332[rbp], 0
	jns	.L96
	lea	rdi, .LC28[rip]
	call	perror@PLT
	jmp	.L97
.L96:
	mov	edx, DWORD PTR -356[rbp]
	mov	eax, DWORD PTR -332[rbp]
	mov	esi, eax
	lea	rdi, .LC29[rip]
	mov	eax, 0
	call	printf@PLT
.L97:
	mov	eax, DWORD PTR child_to_wait_for[rip]
	sub	eax, 1
	mov	DWORD PTR child_to_wait_for[rip], eax
.L95:
	mov	eax, DWORD PTR child_to_wait_for[rip]
	test	eax, eax
	jg	.L98
	mov	DWORD PTR -360[rbp], 128
	lea	rdx, -360[rbp]
	lea	rcx, -144[rbp]
	mov	eax, DWORD PTR -348[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	accept@PLT
	mov	DWORD PTR -336[rbp], eax
	cmp	DWORD PTR -336[rbp], 0
	jns	.L99
	lea	rdi, .LC30[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L110
.L99:
	lea	rdi, .LC31[rip]
	call	puts@PLT
	call	fork@PLT
	mov	DWORD PTR -332[rbp], eax
	cmp	DWORD PTR -332[rbp], 0
	jns	.L100
	lea	rdi, .LC32[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L110
.L100:
	cmp	DWORD PTR -332[rbp], 0
	jne	.L101
	mov	DWORD PTR -340[rbp], 1
	mov	eax, DWORD PTR -348[rbp]
	mov	edi, eax
	call	close@PLT
	mov	DWORD PTR -348[rbp], -1
	mov	eax, DWORD PTR -336[rbp]
	mov	edi, eax
	call	handle_http_connection
.L101:
	mov	eax, DWORD PTR -336[rbp]
	mov	edi, eax
	call	close@PLT
.L94:
	cmp	DWORD PTR -340[rbp], 0
	jne	.L102
	mov	eax, DWORD PTR quit[rip]
	test	eax, eax
	je	.L95
.L102:
	cmp	DWORD PTR -348[rbp], 0
	js	.L104
	mov	eax, DWORD PTR -348[rbp]
	mov	edi, eax
	call	close@PLT
	mov	DWORD PTR -348[rbp], -1
.L104:
	cmp	DWORD PTR -340[rbp], 0
	jne	.L105
	jmp	.L106
.L109:
	lea	rax, -356[rbp]
	mov	rdi, rax
	call	wait@PLT
	mov	DWORD PTR -332[rbp], eax
	cmp	DWORD PTR -332[rbp], 0
	jns	.L107
	lea	rdi, .LC28[rip]
	call	perror@PLT
	jmp	.L108
.L107:
	mov	edx, DWORD PTR -356[rbp]
	mov	eax, DWORD PTR -332[rbp]
	mov	esi, eax
	lea	rdi, .LC29[rip]
	mov	eax, 0
	call	printf@PLT
.L108:
	mov	eax, DWORD PTR child_to_wait_for[rip]
	sub	eax, 1
	mov	DWORD PTR child_to_wait_for[rip], eax
.L106:
	mov	eax, DWORD PTR child_to_wait_for[rip]
	test	eax, eax
	jg	.L109
	lea	rdi, .LC33[rip]
	call	puts@PLT
.L105:
	mov	eax, 0
.L110:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L111
	call	__stack_chk_fail@PLT
.L111:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	main, .-main
	.section	.rodata
	.align 8
	.type	crap.0, @object
	.size	crap.0, 9
crap.0:
	.string	"_CRAP_\r\n"
	.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	"314892.c"
	.text
	.global	quit
	.bss
	.align	2
	.type	quit, %object
	.size	quit, 4
quit:
	.space	4
	.global	child_to_wait_for
	.align	2
	.type	child_to_wait_for, %object
	.size	child_to_wait_for, 4
child_to_wait_for:
	.space	4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"handle_signal_chld(%d)\012\000"
	.text
	.align	2
	.global	handle_signal_chld
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_signal_chld, %function
handle_signal_chld:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L2
	bl	printf
	ldr	r3, .L2+4
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L2+4
	str	r3, [r2]
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L3:
	.align	2
.L2:
	.word	.LC0
	.word	child_to_wait_for
	.size	handle_signal_chld, .-handle_signal_chld
	.section	.rodata
	.align	2
.LC1:
	.ascii	"%04d_ABCDEFGHIJKL_This_line_is_64_bytes_long_ABCDEF"
	.ascii	"GHIJKL_%04d\015\012\000"
	.align	2
.LC2:
	.ascii	"snprintf() returned %d in build_content()\012\000"
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	build_content
	.syntax unified
	.arm
	.fpu softvfp
	.type	build_content, %function
build_content:
	@ args = 0, pretend = 0, frame = 104
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #112
	str	r0, [fp, #-104]
	str	r1, [fp, #-108]
	ldr	r3, .L10
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-96]
	b	.L5
.L8:
	sub	r0, fp, #88
	ldr	r3, [fp, #-96]
	str	r3, [sp]
	ldr	r3, [fp, #-96]
	ldr	r2, .L10+4
	mov	r1, #80
	bl	snprintf
	str	r0, [fp, #-92]
	ldr	r3, [fp, #-92]
	cmp	r3, #64
	beq	.L6
	ldr	r3, .L10+8
	ldr	r3, [r3]
	ldr	r2, [fp, #-92]
	ldr	r1, .L10+12
	mov	r0, r3
	bl	fprintf
.L6:
	ldr	r3, [fp, #-96]
	add	r3, r3, #1
	str	r3, [fp, #-96]
	ldr	r3, [fp, #-108]
	cmp	r3, #63
	ble	.L7
	sub	r3, fp, #88
	mov	r2, #64
	mov	r1, r3
	ldr	r0, [fp, #-104]
	bl	memcpy
	ldr	r3, [fp, #-104]
	add	r3, r3, #64
	str	r3, [fp, #-104]
	ldr	r3, [fp, #-108]
	sub	r3, r3, #64
	str	r3, [fp, #-108]
	b	.L5
.L7:
	ldr	r2, [fp, #-108]
	sub	r3, fp, #88
	mov	r1, r3
	ldr	r0, [fp, #-104]
	bl	memcpy
	ldr	r3, [fp, #-108]
	ldr	r2, [fp, #-104]
	add	r3, r2, r3
	str	r3, [fp, #-104]
	mov	r3, #0
	str	r3, [fp, #-108]
.L5:
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	bgt	.L8
	nop
	ldr	r3, .L10
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L9
	bl	__stack_chk_fail
.L9:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L11:
	.align	2
.L10:
	.word	.LC3
	.word	.LC1
	.word	stderr
	.word	.LC2
	.size	build_content, .-build_content
	.align	2
	.global	build_crap
	.syntax unified
	.arm
	.fpu softvfp
	.type	build_crap, %function
build_crap:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	b	.L13
.L15:
	mov	r3, #8
	str	r3, [fp, #-8]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-20]
	cmp	r2, r3
	ble	.L14
	ldr	r3, [fp, #-20]
	str	r3, [fp, #-8]
.L14:
	ldr	r3, [fp, #-8]
	mov	r2, r3
	ldr	r1, .L16
	ldr	r0, [fp, #-16]
	bl	memcpy
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	str	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	ldr	r3, [fp, #-8]
	sub	r3, r2, r3
	str	r3, [fp, #-20]
.L13:
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bgt	.L15
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L17:
	.align	2
.L16:
	.word	crap.6776
	.size	build_crap, .-build_crap
	.section	.rodata
	.align	2
.LC4:
	.ascii	"HTTP/1.1 200 OK\015\012Content-Type: text/plain\015"
	.ascii	"\012Transfer-Encoding: chunked\015\012\015\012\000"
	.align	2
.LC5:
	.ascii	"%x\015\012\000"
	.align	2
.LC6:
	.ascii	"0\015\012\000"
	.align	2
.LC7:
	.ascii	"resp_length=%d buffer_length=%d content_length=%d\012"
	.ascii	"\000"
	.text
	.align	2
	.global	build_chunked_response
	.syntax unified
	.arm
	.fpu softvfp
	.type	build_chunked_response, %function
build_chunked_response:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	ldr	r3, [fp, #-32]
	add	r2, r3, #256
	ldr	r3, [fp, #-32]
	asr	r3, r3, #4
	add	r3, r2, r3
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-16]
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-16]
	ldr	r2, .L23
	mov	r1, r3
	ldr	r0, [fp, #-12]
	bl	snprintf
	mov	r2, r0
	ldr	r3, [fp, #-36]
	str	r2, [r3]
	ldr	r3, [fp, #-32]
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r1, [fp, #-32]
	ldr	r0, [fp, #-8]
	bl	build_content
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L19
.L21:
	bl	rand
	mov	r1, r0
	ldr	r3, .L23+4
	smull	r2, r3, r1, r3
	asr	r2, r3, #6
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r0, r3, #5
	add	r3, r3, r0
	lsl	r3, r3, #1
	add	r3, r3, r2
	sub	r2, r1, r3
	add	r3, r2, #1
	str	r3, [fp, #-20]
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-20]
	add	r3, r2, r3
	ldr	r2, [fp, #-32]
	cmp	r2, r3
	bge	.L20
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-24]
	sub	r3, r2, r3
	str	r3, [fp, #-20]
.L20:
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r0, r3, r2
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	ldr	r2, [fp, #-16]
	sub	r3, r2, r3
	mov	r1, r3
	ldr	r3, [fp, #-20]
	ldr	r2, .L23+8
	bl	snprintf
	mov	r2, r0
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	add	r2, r2, r3
	ldr	r3, [fp, #-36]
	str	r2, [r3]
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r0, r3, r2
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	ldr	r2, [fp, #-20]
	mov	r1, r3
	bl	memcpy
	ldr	r3, [fp, #-36]
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	add	r2, r2, r3
	ldr	r3, [fp, #-36]
	str	r2, [r3]
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-20]
	add	r3, r2, r3
	str	r3, [fp, #-24]
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	add	r1, r3, #1
	ldr	r2, [fp, #-36]
	str	r1, [r2]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r3, r3, r2
	mov	r2, #13
	strb	r2, [r3]
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	add	r1, r3, #1
	ldr	r2, [fp, #-36]
	str	r1, [r2]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r3, r3, r2
	mov	r2, #10
	strb	r2, [r3]
.L19:
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-32]
	cmp	r2, r3
	blt	.L21
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r3, r3, r2
	mov	r2, #3
	ldr	r1, .L23+12
	mov	r0, r3
	bl	memcpy
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	add	r2, r3, #3
	ldr	r3, [fp, #-36]
	str	r2, [r3]
	ldr	r0, [fp, #-8]
	bl	free
	ldr	r3, [fp, #-36]
	ldr	r1, [r3]
	ldr	r3, [fp, #-32]
	ldr	r2, [fp, #-16]
	ldr	r0, .L23+16
	bl	printf
	ldr	r3, [fp, #-12]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L24:
	.align	2
.L23:
	.word	.LC4
	.word	1381296015
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.size	build_chunked_response, .-build_chunked_response
	.global	modes_array
	.section	.rodata
	.align	2
.LC8:
	.ascii	"chunked\000"
	.align	2
.LC9:
	.ascii	"addcrap\000"
	.align	2
.LC10:
	.ascii	"normal\000"
	.align	2
	.type	modes_array, %object
	.size	modes_array, 32
modes_array:
	.word	1
	.word	.LC8
	.word	2
	.word	.LC9
	.word	3
	.word	.LC10
	.word	0
	.word	0
	.align	2
.LC11:
	.ascii	"write\000"
	.text
	.align	2
	.global	send_response
	.syntax unified
	.arm
	.fpu softvfp
	.type	send_response, %function
send_response:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	b	.L26
.L30:
	bl	rand
	mov	r2, r0
	ldr	r3, .L31
	smull	r1, r3, r2, r3
	add	r3, r3, r2
	asr	r1, r3, #6
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #1
	add	r3, r3, r1
	lsl	r1, r3, #5
	add	r3, r3, r1
	sub	r1, r2, r3
	add	r3, r1, #1
	str	r3, [fp, #-8]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-24]
	cmp	r2, r3
	ble	.L27
	ldr	r3, [fp, #-24]
	str	r3, [fp, #-8]
.L27:
	ldr	r3, [fp, #-8]
	mov	r2, r3
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	write
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bge	.L28
	ldr	r0, .L31+4
	bl	perror
	b	.L25
.L28:
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-8]
	sub	r3, r2, r3
	str	r3, [fp, #-24]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	add	r3, r2, r3
	str	r3, [fp, #-20]
	ldr	r0, .L31+8
	bl	usleep
.L26:
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	bgt	.L30
.L25:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L32:
	.align	2
.L31:
	.word	-1518422781
	.word	.LC11
	.word	10000
	.size	send_response, .-send_response
	.section	.rodata
	.align	2
.LC12:
	.ascii	"read\000"
	.align	2
.LC13:
	.ascii	"\015\012\015\012\000"
	.align	2
.LC14:
	.ascii	"headers :\012%.*s\000"
	.align	2
.LC15:
	.ascii	"Method = %s, URI = %s, %s\012\000"
	.align	2
.LC16:
	.ascii	"GET\000"
	.align	2
.LC18:
	.ascii	"HTTP/1.1 200 OK\015\012Server: minihttptestserver\015"
	.ascii	"\012Content-Type: text/plain\015\012Content-Length:"
	.ascii	" %d\015\012\015\012\000"
	.align	2
.LC19:
	.ascii	"HTTP/1.1 200 OK\015\012Server: minihttptestserver\015"
	.ascii	"\012Content-Type: text/plain\015\012\015\012\000"
	.align	2
.LC17:
	.ascii	"HTTP/1.1 405 Method Not Allowed\015\012Allow: GET\015"
	.ascii	"\012\015\012\000"
	.align	2
.LC20:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	handle_http_connection
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_http_connection, %function
handle_http_connection:
	@ args = 0, pretend = 0, frame = 2440
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2432
	sub	sp, sp, #8
	str	r0, [fp, #-2440]
	ldr	r3, .L76
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-2428]
	mov	r3, #0
	str	r3, [fp, #-2424]
	mov	r3, #16384
	str	r3, [fp, #-2396]
	b	.L34
.L42:
	ldr	r2, [fp, #-2428]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	add	r1, r3, r2
	ldr	r3, [fp, #-2428]
	rsb	r3, r3, #2048
	mov	r2, r3
	ldr	r0, [fp, #-2440]
	bl	read
	str	r0, [fp, #-2420]
	ldr	r3, [fp, #-2420]
	cmp	r3, #0
	bge	.L35
	ldr	r0, .L76+4
	bl	perror
	b	.L33
.L35:
	ldr	r3, [fp, #-2420]
	cmp	r3, #0
	beq	.L74
	ldr	r2, [fp, #-2428]
	ldr	r3, [fp, #-2420]
	add	r3, r2, r3
	str	r3, [fp, #-2428]
	mov	r3, #0
	str	r3, [fp, #-2416]
	b	.L39
.L41:
	ldr	r2, [fp, #-2416]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	add	r3, r3, r2
	mov	r2, #4
	ldr	r1, .L76+8
	mov	r0, r3
	bl	memcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L40
	mov	r3, #1
	str	r3, [fp, #-2424]
	b	.L34
.L40:
	ldr	r3, [fp, #-2416]
	add	r3, r3, #1
	str	r3, [fp, #-2416]
.L39:
	ldr	r3, [fp, #-2428]
	sub	r3, r3, #3
	ldr	r2, [fp, #-2416]
	cmp	r2, r3
	blt	.L41
.L34:
	ldr	r3, [fp, #-2428]
	cmp	r3, #2048
	bge	.L38
	ldr	r3, [fp, #-2424]
	cmp	r3, #0
	beq	.L42
	b	.L38
.L74:
	nop
.L38:
	ldr	r3, [fp, #-2424]
	cmp	r3, #0
	beq	.L75
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, r3
	ldr	r1, [fp, #-2428]
	ldr	r0, .L76+12
	bl	printf
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	str	r3, [fp, #-2412]
	mov	r3, #0
	str	r3, [fp, #-2416]
	b	.L44
.L46:
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L45
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #13
	beq	.L45
	ldr	r3, [fp, #-2412]
	ldrb	r1, [r3]	@ zero_extendqisi2
	sub	r3, fp, #2384
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, [fp, #-2416]
	add	r3, r3, r2
	mov	r2, r1
	strb	r2, [r3]
	ldr	r3, [fp, #-2412]
	add	r3, r3, #1
	str	r3, [fp, #-2412]
	ldr	r3, [fp, #-2416]
	add	r3, r3, #1
	str	r3, [fp, #-2416]
.L44:
	ldr	r3, [fp, #-2416]
	cmp	r3, #14
	ble	.L46
.L45:
	sub	r3, fp, #2384
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, [fp, #-2416]
	add	r3, r3, r2
	mov	r2, #0
	strb	r2, [r3]
	b	.L47
.L48:
	ldr	r3, [fp, #-2412]
	add	r3, r3, #1
	str	r3, [fp, #-2412]
.L47:
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L48
	mov	r3, #0
	str	r3, [fp, #-2416]
	b	.L49
.L51:
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L50
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #13
	beq	.L50
	ldr	r3, [fp, #-2412]
	ldrb	r1, [r3]	@ zero_extendqisi2
	sub	r3, fp, #2304
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, [fp, #-2416]
	add	r3, r3, r2
	mov	r2, r1
	strb	r2, [r3]
	ldr	r3, [fp, #-2412]
	add	r3, r3, #1
	str	r3, [fp, #-2412]
	ldr	r3, [fp, #-2416]
	add	r3, r3, #1
	str	r3, [fp, #-2416]
.L49:
	ldr	r3, [fp, #-2416]
	cmp	r3, #254
	ble	.L51
.L50:
	sub	r3, fp, #2304
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, [fp, #-2416]
	add	r3, r3, r2
	mov	r2, #0
	strb	r2, [r3]
	b	.L52
.L53:
	ldr	r3, [fp, #-2412]
	add	r3, r3, #1
	str	r3, [fp, #-2412]
.L52:
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L53
	mov	r3, #0
	str	r3, [fp, #-2416]
	b	.L54
.L56:
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L55
	ldr	r3, [fp, #-2412]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #13
	beq	.L55
	ldr	r3, [fp, #-2412]
	ldrb	r1, [r3]	@ zero_extendqisi2
	sub	r3, fp, #2368
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, [fp, #-2416]
	add	r3, r3, r2
	mov	r2, r1
	strb	r2, [r3]
	ldr	r3, [fp, #-2412]
	add	r3, r3, #1
	str	r3, [fp, #-2412]
	ldr	r3, [fp, #-2416]
	add	r3, r3, #1
	str	r3, [fp, #-2416]
.L54:
	ldr	r3, [fp, #-2416]
	cmp	r3, #14
	ble	.L56
.L55:
	sub	r3, fp, #2368
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r2, [fp, #-2416]
	add	r3, r3, r2
	mov	r2, #0
	strb	r2, [r3]
	sub	r3, fp, #2368
	sub	r3, r3, #4
	sub	r3, r3, #4
	sub	r2, fp, #2304
	sub	r2, r2, #4
	sub	r2, r2, #4
	sub	r1, fp, #2384
	sub	r1, r1, #4
	sub	r1, r1, #4
	ldr	r0, .L76+16
	bl	printf
	sub	r3, fp, #2384
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r1, .L76+20
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L57
	ldr	r3, .L76+24
	sub	ip, fp, #2352
	sub	ip, ip, #4
	sub	ip, ip, #4
	mov	lr, r3
	ldmia	lr!, {r0, r1, r2, r3}
	stmia	ip!, {r0, r1, r2, r3}
	ldmia	lr!, {r0, r1, r2, r3}
	stmia	ip!, {r0, r1, r2, r3}
	ldm	lr, {r0, r1, r2, r3}
	stm	ip, {r0, r1, r2, r3}
	mov	r3, #47
	str	r3, [fp, #-2420]
	sub	r3, fp, #2352
	sub	r3, r3, #4
	sub	r3, r3, #4
	str	r3, [fp, #-2400]
	b	.L58
.L61:
	ldr	r3, [fp, #-2420]
	mov	r2, r3
	ldr	r1, [fp, #-2400]
	ldr	r0, [fp, #-2440]
	bl	write
	str	r0, [fp, #-2416]
	ldr	r3, [fp, #-2416]
	cmp	r3, #0
	bge	.L59
	ldr	r0, .L76+28
	bl	perror
	b	.L33
.L59:
	ldr	r2, [fp, #-2420]
	ldr	r3, [fp, #-2416]
	sub	r3, r2, r3
	str	r3, [fp, #-2420]
	ldr	r3, [fp, #-2416]
	ldr	r2, [fp, #-2400]
	add	r3, r2, r3
	str	r3, [fp, #-2400]
.L58:
	ldr	r3, [fp, #-2420]
	cmp	r3, #0
	bgt	.L61
	b	.L33
.L57:
	mov	r3, #0
	str	r3, [fp, #-2404]
	mov	r3, #0
	str	r3, [fp, #-2416]
	b	.L62
.L65:
	ldr	r2, .L76+32
	ldr	r3, [fp, #-2416]
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	sub	r3, fp, #2304
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	strstr
	mov	r3, r0
	cmp	r3, #0
	beq	.L63
	ldr	r2, .L76+32
	ldr	r3, [fp, #-2416]
	ldr	r3, [r2, r3, lsl #3]
	str	r3, [fp, #-2404]
	b	.L64
.L63:
	ldr	r3, [fp, #-2416]
	add	r3, r3, #1
	str	r3, [fp, #-2416]
.L62:
	ldr	r2, .L76+32
	ldr	r3, [fp, #-2416]
	ldr	r3, [r2, r3, lsl #3]
	cmp	r3, #0
	bne	.L65
.L64:
	ldr	r3, [fp, #-2404]
	cmp	r3, #1
	beq	.L66
	ldr	r3, [fp, #-2404]
	cmp	r3, #2
	beq	.L67
	b	.L73
.L66:
	sub	r3, fp, #2416
	sub	r3, r3, #4
	sub	r3, r3, #12
	mov	r1, r3
	ldr	r0, [fp, #-2396]
	bl	build_chunked_response
	str	r0, [fp, #-2408]
	b	.L69
.L67:
	ldr	r3, [fp, #-2396]
	add	r3, r3, #256
	str	r3, [fp, #-2432]
	ldr	r3, [fp, #-2432]
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-2408]
	ldr	r3, [fp, #-2432]
	mov	r1, r3
	ldr	r3, [fp, #-2396]
	ldr	r2, .L76+36
	ldr	r0, [fp, #-2408]
	bl	snprintf
	str	r0, [fp, #-2420]
	ldr	r2, [fp, #-2396]
	ldr	r3, [fp, #-2420]
	add	r3, r2, r3
	add	r3, r3, #2048
	str	r3, [fp, #-2432]
	ldr	r3, [fp, #-2432]
	mov	r1, r3
	ldr	r0, [fp, #-2408]
	bl	realloc
	str	r0, [fp, #-2408]
	ldr	r3, [fp, #-2420]
	ldr	r2, [fp, #-2408]
	add	r3, r2, r3
	ldr	r1, [fp, #-2396]
	mov	r0, r3
	bl	build_content
	ldr	r2, [fp, #-2420]
	ldr	r3, [fp, #-2396]
	add	r3, r2, r3
	ldr	r2, [fp, #-2408]
	add	r3, r2, r3
	mov	r1, #2048
	mov	r0, r3
	bl	build_crap
	b	.L69
.L73:
	ldr	r3, [fp, #-2396]
	add	r3, r3, #256
	str	r3, [fp, #-2432]
	ldr	r3, [fp, #-2432]
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-2408]
	ldr	r3, [fp, #-2432]
	ldr	r2, .L76+40
	mov	r1, r3
	ldr	r0, [fp, #-2408]
	bl	snprintf
	str	r0, [fp, #-2420]
	ldr	r2, [fp, #-2396]
	ldr	r3, [fp, #-2420]
	add	r3, r2, r3
	str	r3, [fp, #-2432]
	ldr	r3, [fp, #-2432]
	mov	r1, r3
	ldr	r0, [fp, #-2408]
	bl	realloc
	str	r0, [fp, #-2408]
	ldr	r3, [fp, #-2420]
	ldr	r2, [fp, #-2408]
	add	r0, r2, r3
	ldr	r2, [fp, #-2432]
	ldr	r3, [fp, #-2420]
	sub	r3, r2, r3
	mov	r1, r3
	bl	build_content
.L69:
	ldr	r3, [fp, #-2408]
	cmp	r3, #0
	beq	.L33
	ldr	r3, [fp, #-2432]
	mov	r2, r3
	ldr	r1, [fp, #-2408]
	ldr	r0, [fp, #-2440]
	bl	send_response
	ldr	r0, [fp, #-2408]
	bl	free
	b	.L33
.L75:
	nop
.L33:
	ldr	r3, .L76
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L72
	bl	__stack_chk_fail
.L72:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L77:
	.align	2
.L76:
	.word	.LC20
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.word	.LC16
	.word	.LC17
	.word	.LC11
	.word	modes_array
	.word	.LC18
	.word	.LC19
	.size	handle_http_connection, .-handle_http_connection
	.section	.rodata
	.align	2
.LC21:
	.ascii	"unknown command line switch '%s'\012\000"
	.align	2
.LC22:
	.ascii	"unkown command line argument '%s'\012\000"
	.align	2
.LC23:
	.ascii	"socket\000"
	.align	2
.LC24:
	.ascii	"bind\000"
	.align	2
.LC25:
	.ascii	"listen\000"
	.align	2
.LC26:
	.ascii	"getsockname\000"
	.align	2
.LC27:
	.ascii	"Listening on port %hu\012\000"
	.align	2
.LC28:
	.ascii	"wb\000"
	.align	2
.LC29:
	.ascii	"error writing to file %s : %dbytes written (out of "
	.ascii	"%d)\012\000"
	.align	2
.LC30:
	.ascii	"error opening file %s for writing\012\000"
	.align	2
.LC31:
	.ascii	"wait\000"
	.align	2
.LC32:
	.ascii	"child(%d) terminated with status %d\012\000"
	.align	2
.LC33:
	.ascii	"accept\000"
	.align	2
.LC34:
	.ascii	"accept...\000"
	.align	2
.LC35:
	.ascii	"fork\000"
	.align	2
.LC36:
	.ascii	"Bye...\000"
	.align	2
.LC37:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 336
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #348
	str	r0, [fp, #-344]
	str	r1, [fp, #-348]
	ldr	r3, .L125
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-324]
	sub	r3, fp, #12
	sub	r3, r3, #324
	sub	r3, r3, #2
	mov	r2, #0
	strh	r2, [r3]	@ movhi
	mov	r3, #0
	str	r3, [fp, #-312]
	mov	r3, #0
	str	r3, [fp, #-308]
	mov	r3, #1
	str	r3, [fp, #-316]
	b	.L79
.L88:
	ldr	r3, [fp, #-316]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-348]
	add	r3, r2, r3
	ldr	r3, [r3]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #45
	bne	.L80
	ldr	r3, [fp, #-316]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-348]
	add	r3, r2, r3
	ldr	r3, [r3]
	add	r3, r3, #1
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #112
	beq	.L81
	cmp	r3, #112
	bgt	.L82
	cmp	r3, #54
	beq	.L83
	cmp	r3, #101
	beq	.L84
	b	.L82
.L83:
	mov	r3, #1
	str	r3, [fp, #-324]
	b	.L87
.L84:
	ldr	r3, [fp, #-316]
	add	r3, r3, #1
	str	r3, [fp, #-316]
	ldr	r3, [fp, #-316]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-348]
	add	r3, r2, r3
	ldr	r3, [r3]
	str	r3, [fp, #-308]
	b	.L87
.L81:
	ldr	r3, [fp, #-316]
	add	r3, r3, #1
	str	r3, [fp, #-316]
	ldr	r2, [fp, #-316]
	ldr	r3, [fp, #-344]
	cmp	r2, r3
	bge	.L124
	ldr	r3, [fp, #-316]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-348]
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r2, r0
	sub	r3, fp, #12
	sub	r3, r3, #324
	sub	r3, r3, #2
	strh	r2, [r3]	@ movhi
	b	.L124
.L82:
	ldr	r3, .L125+4
	ldr	r0, [r3]
	ldr	r3, [fp, #-316]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-348]
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L125+8
	bl	fprintf
	b	.L87
.L80:
	ldr	r3, .L125+4
	ldr	r0, [r3]
	ldr	r3, [fp, #-316]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-348]
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L125+12
	bl	fprintf
	b	.L87
.L124:
	nop
.L87:
	ldr	r3, [fp, #-316]
	add	r3, r3, #1
	str	r3, [fp, #-316]
.L79:
	ldr	r2, [fp, #-316]
	ldr	r3, [fp, #-344]
	cmp	r2, r3
	blt	.L88
	mov	r0, #0
	bl	time
	mov	r3, r0
	mov	r0, r3
	bl	srand
	ldr	r1, .L125+16
	mov	r0, #17
	bl	signal
	ldr	r3, [fp, #-324]
	cmp	r3, #0
	beq	.L89
	mov	r3, #10
	b	.L90
.L89:
	mov	r3, #2
.L90:
	mov	r2, #0
	mov	r1, #1
	mov	r0, r3
	bl	socket
	str	r0, [fp, #-320]
	ldr	r3, [fp, #-320]
	cmp	r3, #0
	bge	.L91
	ldr	r0, .L125+20
	bl	perror
	mov	r3, #1
	b	.L122
.L91:
	sub	r3, fp, #272
	mov	r2, #128
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #144
	mov	r2, #128
	mov	r1, #0
	mov	r0, r3
	bl	memset
	ldr	r3, [fp, #-324]
	cmp	r3, #0
	beq	.L93
	sub	r3, fp, #272
	str	r3, [fp, #-300]
	ldr	r3, [fp, #-300]
	mov	r2, #10
	strh	r2, [r3]	@ movhi
	sub	r3, fp, #12
	sub	r3, r3, #324
	sub	r3, r3, #2
	ldrh	r3, [r3]
	mov	r0, r3
	bl	htons
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-300]
	strh	r2, [r3, #2]	@ movhi
	ldr	r3, [fp, #-300]
	ldr	r2, .L125+24
	add	ip, r3, #8
	mov	r3, r2
	ldm	r3, {r0, r1, r2, r3}
	stm	ip, {r0, r1, r2, r3}
	b	.L94
.L93:
	sub	r3, fp, #272
	str	r3, [fp, #-304]
	ldr	r3, [fp, #-304]
	mov	r2, #2
	strh	r2, [r3]	@ movhi
	sub	r3, fp, #12
	sub	r3, r3, #324
	sub	r3, r3, #2
	ldrh	r3, [r3]
	mov	r0, r3
	bl	htons
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-304]
	strh	r2, [r3, #2]	@ movhi
	ldr	r0, .L125+28
	bl	htonl
	mov	r2, r0
	ldr	r3, [fp, #-304]
	str	r2, [r3, #4]
.L94:
	ldr	r3, [fp, #-324]
	cmp	r3, #0
	beq	.L95
	mov	r2, #28
	b	.L96
.L95:
	mov	r2, #16
.L96:
	sub	r3, fp, #272
	mov	r1, r3
	ldr	r0, [fp, #-320]
	bl	bind
	mov	r3, r0
	cmp	r3, #0
	bge	.L97
	ldr	r0, .L125+32
	bl	perror
	mov	r3, #1
	b	.L122
.L97:
	mov	r1, #5
	ldr	r0, [fp, #-320]
	bl	listen
	mov	r3, r0
	cmp	r3, #0
	bge	.L98
	ldr	r0, .L125+36
	bl	perror
.L98:
	sub	r3, fp, #12
	sub	r3, r3, #324
	sub	r3, r3, #2
	ldrh	r3, [r3]
	cmp	r3, #0
	bne	.L99
	mov	r3, #128
	str	r3, [fp, #-336]
	sub	r2, fp, #336
	sub	r3, fp, #272
	mov	r1, r3
	ldr	r0, [fp, #-320]
	bl	getsockname
	mov	r3, r0
	cmp	r3, #0
	bge	.L100
	ldr	r0, .L125+40
	bl	perror
	mov	r3, #1
	b	.L122
.L100:
	ldr	r3, [fp, #-324]
	cmp	r3, #0
	beq	.L101
	sub	r3, fp, #272
	str	r3, [fp, #-292]
	ldr	r3, [fp, #-292]
	ldrh	r3, [r3, #2]
	sub	r2, fp, #12
	sub	r4, r2, #324
	sub	r4, r4, #2
	mov	r0, r3
	bl	ntohs
	mov	r3, r0
	strh	r3, [r4]	@ movhi
	b	.L102
.L101:
	sub	r3, fp, #272
	str	r3, [fp, #-296]
	ldr	r3, [fp, #-296]
	ldrh	r3, [r3, #2]
	sub	r2, fp, #12
	sub	r4, r2, #324
	sub	r4, r4, #2
	mov	r0, r3
	bl	ntohs
	mov	r3, r0
	strh	r3, [r4]	@ movhi
.L102:
	sub	r3, fp, #12
	sub	r3, r3, #324
	sub	r3, r3, #2
	ldrh	r3, [r3]
	mov	r1, r3
	ldr	r0, .L125+44
	bl	printf
	ldr	r3, .L125+48
	ldr	r3, [r3]
	mov	r0, r3
	bl	fflush
.L99:
	ldr	r3, [fp, #-308]
	cmp	r3, #0
	beq	.L106
	ldr	r1, .L125+52
	ldr	r0, [fp, #-308]
	bl	fopen
	str	r0, [fp, #-288]
	ldr	r3, [fp, #-288]
	cmp	r3, #0
	beq	.L104
	mov	r0, #16384
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-284]
	mov	r1, #16384
	ldr	r0, [fp, #-284]
	bl	build_content
	ldr	r3, [fp, #-288]
	mov	r2, #16384
	mov	r1, #1
	ldr	r0, [fp, #-284]
	bl	fwrite
	mov	r3, r0
	str	r3, [fp, #-316]
	ldr	r3, [fp, #-316]
	cmp	r3, #16384
	beq	.L105
	ldr	r3, .L125+4
	ldr	r0, [r3]
	mov	r3, #16384
	str	r3, [sp]
	ldr	r3, [fp, #-316]
	ldr	r2, [fp, #-308]
	ldr	r1, .L125+56
	bl	fprintf
.L105:
	ldr	r0, [fp, #-284]
	bl	free
	ldr	r0, [fp, #-288]
	bl	fclose
	b	.L106
.L104:
	ldr	r3, .L125+4
	ldr	r3, [r3]
	ldr	r2, [fp, #-308]
	ldr	r1, .L125+60
	mov	r0, r3
	bl	fprintf
	b	.L106
.L110:
	sub	r3, fp, #328
	mov	r0, r3
	bl	wait
	str	r0, [fp, #-276]
	ldr	r3, [fp, #-276]
	cmp	r3, #0
	bge	.L108
	ldr	r0, .L125+64
	bl	perror
	b	.L109
.L108:
	ldr	r3, [fp, #-328]
	mov	r2, r3
	ldr	r1, [fp, #-276]
	ldr	r0, .L125+68
	bl	printf
.L109:
	ldr	r3, .L125+72
	ldr	r3, [r3]
	sub	r3, r3, #1
	ldr	r2, .L125+72
	str	r3, [r2]
.L107:
	ldr	r3, .L125+72
	ldr	r3, [r3]
	cmp	r3, #0
	bgt	.L110
	mov	r3, #128
	str	r3, [fp, #-332]
	sub	r2, fp, #332
	sub	r3, fp, #144
	mov	r1, r3
	ldr	r0, [fp, #-320]
	bl	accept
	str	r0, [fp, #-280]
	ldr	r3, [fp, #-280]
	cmp	r3, #0
	bge	.L111
	ldr	r0, .L125+76
	bl	perror
	mov	r3, #1
	b	.L122
.L111:
	ldr	r0, .L125+80
	bl	puts
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-276]
	ldr	r3, [fp, #-276]
	cmp	r3, #0
	bge	.L112
	ldr	r0, .L125+84
	bl	perror
	mov	r3, #1
	b	.L122
.L112:
	ldr	r3, [fp, #-276]
	cmp	r3, #0
	bne	.L113
	mov	r3, #1
	str	r3, [fp, #-312]
	ldr	r0, [fp, #-320]
	bl	close
	mvn	r3, #0
	str	r3, [fp, #-320]
	ldr	r0, [fp, #-280]
	bl	handle_http_connection
.L113:
	ldr	r0, [fp, #-280]
	bl	close
.L106:
	ldr	r3, [fp, #-312]
	cmp	r3, #0
	bne	.L114
	ldr	r3, .L125+88
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L107
.L114:
	ldr	r3, [fp, #-320]
	cmp	r3, #0
	blt	.L116
	ldr	r0, [fp, #-320]
	bl	close
	mvn	r3, #0
	str	r3, [fp, #-320]
.L116:
	ldr	r3, [fp, #-312]
	cmp	r3, #0
	bne	.L117
	b	.L118
.L121:
	sub	r3, fp, #328
	mov	r0, r3
	bl	wait
	str	r0, [fp, #-276]
	ldr	r3, [fp, #-276]
	cmp	r3, #0
	bge	.L119
	ldr	r0, .L125+64
	bl	perror
	b	.L120
.L119:
	ldr	r3, [fp, #-328]
	mov	r2, r3
	ldr	r1, [fp, #-276]
	ldr	r0, .L125+68
	bl	printf
.L120:
	ldr	r3, .L125+72
	ldr	r3, [r3]
	sub	r3, r3, #1
	ldr	r2, .L125+72
	str	r3, [r2]
.L118:
	ldr	r3, .L125+72
	ldr	r3, [r3]
	cmp	r3, #0
	bgt	.L121
	ldr	r0, .L125+92
	bl	puts
.L117:
	mov	r3, #0
.L122:
	ldr	r2, .L125
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L123
	bl	__stack_chk_fail
.L123:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L126:
	.align	2
.L125:
	.word	.LC37
	.word	stderr
	.word	.LC21
	.word	.LC22
	.word	handle_signal_chld
	.word	.LC23
	.word	in6addr_loopback
	.word	2130706433
	.word	.LC24
	.word	.LC25
	.word	.LC26
	.word	.LC27
	.word	stdout
	.word	.LC28
	.word	.LC29
	.word	.LC30
	.word	.LC31
	.word	.LC32
	.word	child_to_wait_for
	.word	.LC33
	.word	.LC34
	.word	.LC35
	.word	quit
	.word	.LC36
	.size	main, .-main
	.section	.rodata
	.align	2
	.type	crap.6776, %object
	.size	crap.6776, 9
crap.6776:
	.ascii	"_CRAP_\015\012\000"
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
