	.file	"203970.c"
	.intel_syntax noprefix
	.text
	.local	cmd_quit
	.comm	cmd_quit,4,4
	.local	fdtty_pid
	.comm	fdtty_pid,4,4
	.local	daemon_port
	.comm	daemon_port,4,4
	.section	.rodata
.LC0:
	.string	"Daemon fork"
.LC1:
	.string	"Daemon fork tty\n"
.LC2:
	.string	"Daemon socket"
.LC3:
	.string	"Daemon bind port"
.LC4:
	.string	"Daemon listen"
.LC5:
	.string	"error"
	.text
	.globl	daemonize
	.type	daemonize, @function
daemonize:
.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, 64
	mov	DWORD PTR -52[rbp], edi
	mov	DWORD PTR -56[rbp], esi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -40[rbp], 0
	mov	DWORD PTR -48[rbp], 1
	cmp	DWORD PTR -56[rbp], 0
	je	.L2
	call	fork@PLT
	mov	DWORD PTR -36[rbp], eax
	cmp	DWORD PTR -36[rbp], 0
	jns	.L3
	lea	rdi, .LC0[rip]
	call	perror@PLT
	mov	eax, -1
	jmp	.L12
.L3:
	cmp	DWORD PTR -36[rbp], 0
	jle	.L2
	mov	edi, 0
	call	exit@PLT
.L2:
	mov	eax, DWORD PTR -52[rbp]
	mov	DWORD PTR daemon_port[rip], eax
	call	setsid@PLT
	lea	rsi, sig_term[rip]
	mov	edi, 15
	call	signal@PLT
	lea	rsi, sig_quit[rip]
	mov	edi, 3
	call	signal@PLT
	lea	rsi, sig_int[rip]
	mov	edi, 2
	call	signal@PLT
	mov	esi, 1
	mov	edi, 1
	call	signal@PLT
	lea	rsi, sig_usr1[rip]
	mov	edi, 10
	call	signal@PLT
	lea	rsi, sig_usr2[rip]
	mov	edi, 12
	call	signal@PLT
	mov	esi, 1
	mov	edi, 17
	call	signal@PLT
	mov	esi, 1
	mov	edi, 13
	call	signal@PLT
	lea	rax, -44[rbp]
	mov	ecx, 0
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	forkpty@PLT
	mov	DWORD PTR fdtty_pid[rip], eax
	mov	eax, DWORD PTR fdtty_pid[rip]
	test	eax, eax
	jns	.L5
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	eax, -1
	jmp	.L12
.L5:
	mov	eax, DWORD PTR fdtty_pid[rip]
	test	eax, eax
	jne	.L6
	mov	eax, 0
	jmp	.L12
.L6:
	mov	eax, DWORD PTR -44[rbp]
	mov	edi, eax
	call	set_nonblock
	mov	edx, 6
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -40[rbp], eax
	cmp	DWORD PTR -40[rbp], 0
	jns	.L7
	lea	rdi, .LC2[rip]
	call	perror@PLT
	jmp	.L8
.L7:
	lea	rdx, -48[rbp]
	mov	eax, DWORD PTR -40[rbp]
	mov	r8d, 4
	mov	rcx, rdx
	mov	edx, 2
	mov	esi, 1
	mov	edi, eax
	call	setsockopt@PLT
	lea	rax, -32[rbp]
	mov	QWORD PTR [rax], 0
	mov	QWORD PTR 8[rax], 0
	mov	WORD PTR -32[rbp], 2
	mov	edi, 0
	call	htonl@PLT
	mov	DWORD PTR -28[rbp], eax
	mov	eax, DWORD PTR -52[rbp]
	movzx	eax, ax
	mov	edi, eax
	call	htons@PLT
	mov	WORD PTR -30[rbp], ax
	lea	rax, -32[rbp]
	mov	rcx, rax
	mov	eax, DWORD PTR -40[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	bind@PLT
	test	eax, eax
	jns	.L9
	lea	rdi, .LC3[rip]
	call	perror@PLT
	jmp	.L8
.L9:
	mov	eax, DWORD PTR -40[rbp]
	mov	esi, 5
	mov	edi, eax
	call	listen@PLT
	test	eax, eax
	jns	.L10
	lea	rdi, .LC4[rip]
	call	perror@PLT
	jmp	.L8
.L10:
	mov	edx, DWORD PTR -44[rbp]
	mov	eax, DWORD PTR -40[rbp]
	mov	esi, edx
	mov	edi, eax
	call	daemon_proc
.L8:
	lea	rdi, .LC5[rip]
	call	puts@PLT
	cmp	DWORD PTR -40[rbp], 0
	js	.L11
	mov	eax, DWORD PTR -40[rbp]
	mov	edi, eax
	call	close@PLT
.L11:
	mov	eax, DWORD PTR -44[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, DWORD PTR fdtty_pid[rip]
	mov	esi, 9
	mov	edi, eax
	call	kill@PLT
	mov	edi, -1
	call	exit@PLT
.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
.LFE6:
	.size	daemonize, .-daemonize
	.type	pipe_rw, @function
pipe_rw:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 720
	mov	DWORD PTR -708[rbp], edi
	mov	DWORD PTR -712[rbp], esi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -672[rbp], 0
	mov	QWORD PTR -664[rbp], 10000
	mov	DWORD PTR -692[rbp], 0
.L21:
	mov	eax, 0
	mov	ecx, 16
	lea	rdx, -656[rbp]
	mov	rdi, rdx
#APP
# 181 "the_stack_data/203970.c" 1
	cld; rep; stosq
# 0 "" 2
#NO_APP
	mov	eax, edi
	mov	edx, ecx
	mov	DWORD PTR -688[rbp], edx
	mov	DWORD PTR -684[rbp], eax
	mov	eax, DWORD PTR -708[rbp]
	lea	edx, 63[rax]
	test	eax, eax
	cmovs	eax, edx
	sar	eax, 6
	mov	esi, eax
	movsx	rax, esi
	mov	rdi, QWORD PTR -656[rbp+rax*8]
	mov	eax, DWORD PTR -708[rbp]
	cdq
	shr	edx, 26
	add	eax, edx
	and	eax, 63
	sub	eax, edx
	mov	edx, 1
	mov	ecx, eax
	sal	rdx, cl
	mov	rax, rdx
	or	rdi, rax
	mov	rdx, rdi
	movsx	rax, esi
	mov	QWORD PTR -656[rbp+rax*8], rdx
	mov	eax, DWORD PTR -708[rbp]
	lea	edi, 1[rax]
	lea	rdx, -672[rbp]
	lea	rax, -656[rbp]
	mov	r8, rdx
	mov	ecx, 0
	mov	edx, 0
	mov	rsi, rax
	call	select@PLT
	mov	DWORD PTR -680[rbp], eax
	cmp	DWORD PTR -680[rbp], 0
	jns	.L15
	mov	eax, DWORD PTR -680[rbp]
	jmp	.L22
.L15:
	cmp	DWORD PTR -680[rbp], 0
	jne	.L17
	add	DWORD PTR -692[rbp], 1
	cmp	DWORD PTR -692[rbp], 9
	jle	.L24
	mov	eax, 0
	jmp	.L22
.L17:
	mov	DWORD PTR -692[rbp], 0
	mov	eax, DWORD PTR -708[rbp]
	lea	edx, 63[rax]
	test	eax, eax
	cmovs	eax, edx
	sar	eax, 6
	cdqe
	mov	rsi, QWORD PTR -656[rbp+rax*8]
	mov	eax, DWORD PTR -708[rbp]
	cdq
	shr	edx, 26
	add	eax, edx
	and	eax, 63
	sub	eax, edx
	mov	edx, 1
	mov	ecx, eax
	sal	rdx, cl
	mov	rax, rdx
	and	rax, rsi
	test	rax, rax
	je	.L21
	lea	rax, -528[rbp]
	mov	edx, 512
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	lea	rcx, -528[rbp]
	mov	eax, DWORD PTR -708[rbp]
	mov	edx, 512
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -676[rbp], eax
	cmp	DWORD PTR -676[rbp], 0
	jg	.L20
	mov	eax, -1
	jmp	.L22
.L20:
	mov	eax, DWORD PTR -676[rbp]
	movsx	rdx, eax
	lea	rcx, -528[rbp]
	mov	eax, DWORD PTR -712[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	DWORD PTR -680[rbp], eax
	cmp	DWORD PTR -680[rbp], 0
	jns	.L21
	mov	eax, DWORD PTR -680[rbp]
	jmp	.L22
.L24:
	nop
	jmp	.L21
.L22:
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L23
	call	__stack_chk_fail@PLT
.L23:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	pipe_rw, .-pipe_rw
	.section	.rodata
.LC6:
	.string	"\r\nGood-bye\r\n"
.LC7:
	.string	"\n"
	.text
	.type	daemon_proc, @function
daemon_proc:
.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, 80
	mov	DWORD PTR -68[rbp], edi
	mov	DWORD PTR -72[rbp], esi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, .LC6[rip]
	mov	QWORD PTR -40[rbp], rax
	mov	DWORD PTR -52[rbp], 1
	mov	DWORD PTR -56[rbp], 16
.L34:
	mov	DWORD PTR cmd_quit[rip], 0
	lea	rax, -32[rbp]
	mov	rcx, rax
	lea	rdx, -56[rbp]
	mov	eax, DWORD PTR -68[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	accept@PLT
	mov	DWORD PTR -48[rbp], eax
	cmp	DWORD PTR -48[rbp], 0
	js	.L36
	mov	eax, DWORD PTR -48[rbp]
	mov	edi, eax
	call	set_telnet_mode
	mov	eax, DWORD PTR -72[rbp]
	mov	edi, eax
	call	set_nonblock
	cmp	DWORD PTR -52[rbp], 0
	jne	.L28
	mov	eax, DWORD PTR -72[rbp]
	mov	edx, 2
	lea	rsi, .LC7[rip]
	mov	edi, eax
	call	write@PLT
	mov	DWORD PTR -44[rbp], eax
.L28:
	mov	DWORD PTR -52[rbp], 0
	jmp	.L29
.L33:
	mov	edx, DWORD PTR -48[rbp]
	mov	eax, DWORD PTR -72[rbp]
	mov	esi, edx
	mov	edi, eax
	call	pipe_rw
	mov	DWORD PTR -44[rbp], eax
	cmp	DWORD PTR -44[rbp], 0
	js	.L37
	mov	edx, DWORD PTR -72[rbp]
	mov	eax, DWORD PTR -48[rbp]
	mov	esi, edx
	mov	edi, eax
	call	pipe_rw
	mov	DWORD PTR -44[rbp], eax
	cmp	DWORD PTR -44[rbp], 0
	js	.L38
	cmp	DWORD PTR -44[rbp], 0
	jne	.L29
	nop
.L29:
	mov	eax, DWORD PTR cmd_quit[rip]
	test	eax, eax
	je	.L33
	jmp	.L31
.L37:
	nop
	jmp	.L31
.L38:
	nop
.L31:
	mov	edx, DWORD PTR -48[rbp]
	mov	eax, DWORD PTR -72[rbp]
	mov	esi, edx
	mov	edi, eax
	call	pipe_rw
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	mov	rcx, QWORD PTR -40[rbp]
	mov	eax, DWORD PTR -48[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	DWORD PTR -44[rbp], eax
	mov	eax, DWORD PTR -48[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L34
.L36:
	nop
	jmp	.L34
	.cfi_endproc
.LFE8:
	.size	daemon_proc, .-daemon_proc
	.type	set_nonblock, @function
set_nonblock:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, 0
	mov	esi, 3
	mov	edi, eax
	mov	eax, 0
	call	fcntl@PLT
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	or	ah, 8
	mov	edx, eax
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, 4
	mov	edi, eax
	mov	eax, 0
	call	fcntl@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	set_nonblock, .-set_nonblock
	.type	sig_term, @function
sig_term:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	edi, 100000
	call	usleep@PLT
	mov	eax, DWORD PTR fdtty_pid[rip]
	mov	esi, 9
	mov	edi, eax
	call	kill@PLT
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE10:
	.size	sig_term, .-sig_term
	.type	sig_quit, @function
sig_quit:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	DWORD PTR cmd_quit[rip], 1
	lea	rsi, sig_quit[rip]
	mov	edi, 3
	call	signal@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	sig_quit, .-sig_quit
	.type	sig_usr1, @function
sig_usr1:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	edi, 100000
	call	usleep@PLT
	mov	eax, DWORD PTR fdtty_pid[rip]
	mov	esi, 9
	mov	edi, eax
	call	kill@PLT
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE12:
	.size	sig_usr1, .-sig_usr1
	.type	sig_usr2, @function
sig_usr2:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	eax, DWORD PTR fdtty_pid[rip]
	mov	esi, 10
	mov	edi, eax
	call	kill@PLT
	mov	edi, 100000
	call	usleep@PLT
	mov	eax, DWORD PTR fdtty_pid[rip]
	mov	esi, 9
	mov	edi, eax
	call	kill@PLT
	mov	edi, 100000
	call	usleep@PLT
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE13:
	.size	sig_usr2, .-sig_usr2
	.type	sig_int, @function
sig_int:
.LFB14:
	.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	DWORD PTR ctrl_c[rip], 1
	lea	rsi, sig_int[rip]
	mov	edi, 2
	call	signal@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	sig_int, .-sig_int
	.section	.rodata
.LC8:
	.string	"\377\375\001\377\373\001\377\375\003\377\373\003"
	.text
	.type	set_telnet_mode, @function
set_telnet_mode:
.LFB15:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 560
	mov	DWORD PTR -548[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, .LC8[rip]
	mov	QWORD PTR -536[rbp], rax
	mov	rax, QWORD PTR -536[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	mov	rcx, QWORD PTR -536[rbp]
	mov	eax, DWORD PTR -548[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	DWORD PTR -540[rbp], eax
	lea	rcx, -528[rbp]
	mov	eax, DWORD PTR -548[rbp]
	mov	edx, 512
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -540[rbp], eax
	mov	eax, DWORD PTR -540[rbp]
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L47
	call	__stack_chk_fail@PLT
.L47:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	set_telnet_mode, .-set_telnet_mode
	.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	"203970.c"
	.text
	.local	cmd_quit
	.comm	cmd_quit,4,4
	.local	fdtty_pid
	.comm	fdtty_pid,4,4
	.local	daemon_port
	.comm	daemon_port,4,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Daemon fork\000"
	.align	2
.LC1:
	.ascii	"Daemon fork tty\012\000"
	.align	2
.LC2:
	.ascii	"Daemon socket\000"
	.align	2
.LC3:
	.ascii	"Daemon bind port\000"
	.align	2
.LC4:
	.ascii	"Daemon listen\000"
	.align	2
.LC5:
	.ascii	"error\000"
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	daemonize
	.syntax unified
	.arm
	.fpu softvfp
	.type	daemonize, %function
daemonize:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #56
	str	r0, [fp, #-48]
	str	r1, [fp, #-52]
	ldr	r3, .L14
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-32]
	mov	r3, #1
	str	r3, [fp, #-40]
	ldr	r3, [fp, #-52]
	cmp	r3, #0
	beq	.L2
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bge	.L3
	ldr	r0, .L14+4
	bl	perror
	mvn	r3, #0
	b	.L12
.L3:
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	ble	.L2
	mov	r0, #0
	bl	exit
.L2:
	ldr	r2, .L14+8
	ldr	r3, [fp, #-48]
	str	r3, [r2]
	bl	setsid
	ldr	r1, .L14+12
	mov	r0, #15
	bl	signal
	ldr	r1, .L14+16
	mov	r0, #3
	bl	signal
	ldr	r1, .L14+20
	mov	r0, #2
	bl	signal
	mov	r1, #1
	mov	r0, #1
	bl	signal
	ldr	r1, .L14+24
	mov	r0, #10
	bl	signal
	ldr	r1, .L14+28
	mov	r0, #12
	bl	signal
	mov	r1, #1
	mov	r0, #17
	bl	signal
	mov	r1, #1
	mov	r0, #13
	bl	signal
	sub	r0, fp, #36
	mov	r3, #0
	mov	r2, #0
	mov	r1, #0
	bl	forkpty
	mov	r3, r0
	ldr	r2, .L14+32
	str	r3, [r2]
	ldr	r3, .L14+32
	ldr	r3, [r3]
	cmp	r3, #0
	bge	.L5
	ldr	r0, .L14+36
	bl	perror
	mvn	r3, #0
	b	.L12
.L5:
	ldr	r3, .L14+32
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L6
	mov	r3, #0
	b	.L12
.L6:
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	set_nonblock
	mov	r2, #6
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-32]
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bge	.L7
	ldr	r0, .L14+40
	bl	perror
	b	.L8
.L7:
	sub	r3, fp, #40
	mov	r2, #4
	str	r2, [sp]
	mov	r2, #2
	mov	r1, #1
	ldr	r0, [fp, #-32]
	bl	setsockopt
	sub	r3, fp, #24
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2]
	str	r3, [r2, #4]
	str	r3, [r2, #8]
	str	r3, [r2, #12]
	mov	r3, #2
	strh	r3, [fp, #-24]	@ movhi
	mov	r0, #0
	bl	htonl
	mov	r3, r0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-48]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	mov	r0, r3
	bl	htons
	mov	r3, r0
	strh	r3, [fp, #-22]	@ movhi
	sub	r3, fp, #24
	mov	r2, #16
	mov	r1, r3
	ldr	r0, [fp, #-32]
	bl	bind
	mov	r3, r0
	cmp	r3, #0
	bge	.L9
	ldr	r0, .L14+44
	bl	perror
	b	.L8
.L9:
	mov	r1, #5
	ldr	r0, [fp, #-32]
	bl	listen
	mov	r3, r0
	cmp	r3, #0
	bge	.L10
	ldr	r0, .L14+48
	bl	perror
	b	.L8
.L10:
	ldr	r3, [fp, #-36]
	mov	r1, r3
	ldr	r0, [fp, #-32]
	bl	daemon_proc
.L8:
	ldr	r0, .L14+52
	bl	puts
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	blt	.L11
	ldr	r0, [fp, #-32]
	bl	close
.L11:
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	close
	ldr	r3, .L14+32
	ldr	r3, [r3]
	mov	r1, #9
	mov	r0, r3
	bl	kill
	mvn	r0, #0
	bl	exit
.L12:
	ldr	r2, .L14
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L13
	bl	__stack_chk_fail
.L13:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L15:
	.align	2
.L14:
	.word	.LC6
	.word	.LC0
	.word	daemon_port
	.word	sig_term
	.word	sig_quit
	.word	sig_int
	.word	sig_usr1
	.word	sig_usr2
	.word	fdtty_pid
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	daemonize, .-daemonize
	.section	.rodata
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	pipe_rw, %function
pipe_rw:
	@ args = 0, pretend = 0, frame = 680
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #688
	str	r0, [fp, #-680]
	str	r1, [fp, #-684]
	ldr	r3, .L29
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-656]
	ldr	r3, .L29+4
	str	r3, [fp, #-652]
	mov	r3, #0
	str	r3, [fp, #-676]
.L25:
	sub	r3, fp, #648
	str	r3, [fp, #-668]
	mov	r3, #0
	str	r3, [fp, #-672]
	b	.L17
.L18:
	ldr	r3, [fp, #-668]
	ldr	r2, [fp, #-672]
	mov	r1, #0
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-672]
	add	r3, r3, #1
	str	r3, [fp, #-672]
.L17:
	ldr	r3, [fp, #-672]
	cmp	r3, #31
	bls	.L18
	ldr	r3, [fp, #-680]
	add	r2, r3, #31
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #5
	mov	r2, r3
	lsl	r3, r2, #2
	sub	r1, fp, #4
	add	r3, r1, r3
	ldr	r1, [r3, #-644]
	ldr	r3, [fp, #-680]
	rsbs	r0, r3, #0
	and	r3, r3, #31
	and	r0, r0, #31
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	orr	r1, r1, r3
	lsl	r3, r2, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	str	r1, [r3, #-644]
	ldr	r3, [fp, #-680]
	add	r0, r3, #1
	sub	r1, fp, #648
	sub	r3, fp, #656
	str	r3, [sp]
	mov	r3, #0
	mov	r2, #0
	bl	select
	str	r0, [fp, #-664]
	ldr	r3, [fp, #-664]
	cmp	r3, #0
	bge	.L19
	ldr	r3, [fp, #-664]
	b	.L26
.L19:
	ldr	r3, [fp, #-664]
	cmp	r3, #0
	bne	.L21
	ldr	r3, [fp, #-676]
	add	r3, r3, #1
	str	r3, [fp, #-676]
	ldr	r3, [fp, #-676]
	cmp	r3, #9
	ble	.L28
	mov	r3, #0
	b	.L26
.L21:
	mov	r3, #0
	str	r3, [fp, #-676]
	ldr	r3, [fp, #-680]
	add	r2, r3, #31
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #5
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r2, [r3, #-644]
	ldr	r3, [fp, #-680]
	rsbs	r1, r3, #0
	and	r3, r3, #31
	and	r1, r1, #31
	rsbpl	r3, r1, #0
	mov	r1, #1
	lsl	r3, r1, r3
	and	r3, r3, r2
	cmp	r3, #0
	beq	.L25
	sub	r3, fp, #520
	mov	r2, #512
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #520
	mov	r2, #512
	mov	r1, r3
	ldr	r0, [fp, #-680]
	bl	read
	str	r0, [fp, #-660]
	ldr	r3, [fp, #-660]
	cmp	r3, #0
	bgt	.L24
	mvn	r3, #0
	b	.L26
.L24:
	ldr	r2, [fp, #-660]
	sub	r3, fp, #520
	mov	r1, r3
	ldr	r0, [fp, #-684]
	bl	write
	str	r0, [fp, #-664]
	ldr	r3, [fp, #-664]
	cmp	r3, #0
	bge	.L25
	ldr	r3, [fp, #-664]
	b	.L26
.L28:
	nop
	b	.L25
.L26:
	ldr	r2, .L29
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L27
	bl	__stack_chk_fail
.L27:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L30:
	.align	2
.L29:
	.word	.LC7
	.word	10000
	.size	pipe_rw, .-pipe_rw
	.section	.rodata
	.align	2
.LC8:
	.ascii	"\015\012Good-bye\015\012\000"
	.align	2
.LC9:
	.ascii	"\012\000"
	.align	2
.LC10:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	daemon_proc, %function
daemon_proc:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #48
	str	r0, [fp, #-48]
	str	r1, [fp, #-52]
	ldr	r3, .L45
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, .L45+4
	str	r3, [fp, #-36]
	mov	r3, #1
	str	r3, [fp, #-40]
	mov	r3, #16
	str	r3, [fp, #-44]
.L40:
	ldr	r3, .L45+8
	mov	r2, #0
	str	r2, [r3]
	sub	r3, fp, #24
	mov	r1, r3
	sub	r3, fp, #44
	mov	r2, r3
	ldr	r0, [fp, #-48]
	bl	accept
	str	r0, [fp, #-32]
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	blt	.L42
	ldr	r0, [fp, #-32]
	bl	set_telnet_mode
	ldr	r0, [fp, #-52]
	bl	set_nonblock
	ldr	r3, [fp, #-40]
	cmp	r3, #0
	bne	.L34
	mov	r2, #2
	ldr	r1, .L45+12
	ldr	r0, [fp, #-52]
	bl	write
	str	r0, [fp, #-28]
.L34:
	mov	r3, #0
	str	r3, [fp, #-40]
	b	.L35
.L39:
	ldr	r1, [fp, #-32]
	ldr	r0, [fp, #-52]
	bl	pipe_rw
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	blt	.L43
	ldr	r1, [fp, #-52]
	ldr	r0, [fp, #-32]
	bl	pipe_rw
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	blt	.L44
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L35
	nop
.L35:
	ldr	r3, .L45+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L39
	b	.L37
.L43:
	nop
	b	.L37
.L44:
	nop
.L37:
	ldr	r1, [fp, #-32]
	ldr	r0, [fp, #-52]
	bl	pipe_rw
	ldr	r0, [fp, #-36]
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	ldr	r1, [fp, #-36]
	ldr	r0, [fp, #-32]
	bl	write
	str	r0, [fp, #-28]
	ldr	r0, [fp, #-32]
	bl	close
	b	.L40
.L42:
	nop
	b	.L40
.L46:
	.align	2
.L45:
	.word	.LC10
	.word	.LC8
	.word	cmd_quit
	.word	.LC9
	.size	daemon_proc, .-daemon_proc
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	set_nonblock, %function
set_nonblock:
	@ 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]
	mov	r2, #0
	mov	r1, #3
	ldr	r0, [fp, #-16]
	bl	fcntl
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	orr	r3, r3, #2048
	mov	r2, r3
	mov	r1, #4
	ldr	r0, [fp, #-16]
	bl	fcntl
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	set_nonblock, .-set_nonblock
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	sig_term, %function
sig_term:
	@ 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	r0, .L49
	bl	usleep
	ldr	r3, .L49+4
	ldr	r3, [r3]
	mov	r1, #9
	mov	r0, r3
	bl	kill
	mov	r0, #0
	bl	exit
.L50:
	.align	2
.L49:
	.word	100000
	.word	fdtty_pid
	.size	sig_term, .-sig_term
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	sig_quit, %function
sig_quit:
	@ 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	r3, .L52
	mov	r2, #1
	str	r2, [r3]
	ldr	r1, .L52+4
	mov	r0, #3
	bl	signal
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L53:
	.align	2
.L52:
	.word	cmd_quit
	.word	sig_quit
	.size	sig_quit, .-sig_quit
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	sig_usr1, %function
sig_usr1:
	@ 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	r0, .L55
	bl	usleep
	ldr	r3, .L55+4
	ldr	r3, [r3]
	mov	r1, #9
	mov	r0, r3
	bl	kill
	mov	r0, #0
	bl	exit
.L56:
	.align	2
.L55:
	.word	100000
	.word	fdtty_pid
	.size	sig_usr1, .-sig_usr1
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	sig_usr2, %function
sig_usr2:
	@ 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	r3, .L58
	ldr	r3, [r3]
	mov	r1, #10
	mov	r0, r3
	bl	kill
	ldr	r0, .L58+4
	bl	usleep
	ldr	r3, .L58
	ldr	r3, [r3]
	mov	r1, #9
	mov	r0, r3
	bl	kill
	ldr	r0, .L58+4
	bl	usleep
	mov	r0, #0
	bl	exit
.L59:
	.align	2
.L58:
	.word	fdtty_pid
	.word	100000
	.size	sig_usr2, .-sig_usr2
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	sig_int, %function
sig_int:
	@ 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	r3, .L61
	mov	r2, #1
	str	r2, [r3]
	ldr	r1, .L61+4
	mov	r0, #2
	bl	signal
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L62:
	.align	2
.L61:
	.word	ctrl_c
	.word	sig_int
	.size	sig_int, .-sig_int
	.section	.rodata
	.align	2
.LC11:
	.ascii	"\377\375\001\377\373\001\377\375\003\377\373\003\000"
	.align	2
.LC12:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	set_telnet_mode, %function
set_telnet_mode:
	@ args = 0, pretend = 0, frame = 536
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #536
	str	r0, [fp, #-536]
	ldr	r3, .L66
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, .L66+4
	str	r3, [fp, #-528]
	ldr	r0, [fp, #-528]
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	ldr	r1, [fp, #-528]
	ldr	r0, [fp, #-536]
	bl	write
	str	r0, [fp, #-524]
	sub	r3, fp, #520
	mov	r2, #512
	mov	r1, r3
	ldr	r0, [fp, #-536]
	bl	read
	str	r0, [fp, #-524]
	ldr	r3, [fp, #-524]
	ldr	r2, .L66
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L65
	bl	__stack_chk_fail
.L65:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L67:
	.align	2
.L66:
	.word	.LC12
	.word	.LC11
	.size	set_telnet_mode, .-set_telnet_mode
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
