	.file	"484654.c"
	.intel_syntax noprefix
	.text
	.globl	old_termios
	.bss
	.align 32
	.type	old_termios, @object
	.size	old_termios, 60
old_termios:
	.zero	60
	.globl	port_flag
	.align 4
	.type	port_flag, @object
	.size	port_flag, 4
port_flag:
	.zero	4
	.globl	log_flag
	.align 4
	.type	log_flag, @object
	.size	log_flag, 4
log_flag:
	.zero	4
	.globl	compress_flag
	.align 4
	.type	compress_flag, @object
	.size	compress_flag, 4
compress_flag:
	.zero	4
	.globl	port
	.data
	.align 4
	.type	port, @object
	.size	port, 4
port:
	.long	-1
	.globl	log_fd
	.align 4
	.type	log_fd, @object
	.size	log_fd, 4
log_fd:
	.long	-1
	.globl	deflate_stream
	.bss
	.align 32
	.type	deflate_stream, @object
	.size	deflate_stream, 112
deflate_stream:
	.zero	112
	.globl	inflate_stream
	.align 32
	.type	inflate_stream, @object
	.size	inflate_stream, 112
inflate_stream:
	.zero	112
	.section	.rodata
	.align 8
.LC0:
	.string	"Error getting terminal parameters: %s\n"
	.text
	.globl	safe_tcgetattr
	.type	safe_tcgetattr, @function
safe_tcgetattr:
.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	QWORD PTR -16[rbp], rsi
	mov	rdx, QWORD PTR -16[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	tcgetattr@PLT
	cmp	eax, -1
	jne	.L3
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	safe_tcgetattr, .-safe_tcgetattr
	.section	.rodata
	.align 8
.LC1:
	.string	"Error setting terminal parameters: %s\n"
	.text
	.globl	safe_tcsetattr
	.type	safe_tcsetattr, @function
safe_tcsetattr:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	DWORD PTR -8[rbp], esi
	mov	QWORD PTR -16[rbp], rdx
	mov	rdx, QWORD PTR -16[rbp]
	mov	ecx, DWORD PTR -8[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	tcsetattr@PLT
	cmp	eax, -1
	jne	.L6
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L6:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	safe_tcsetattr, .-safe_tcsetattr
	.globl	save_terminal_params
	.type	save_terminal_params, @function
save_terminal_params:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rsi, old_termios[rip]
	mov	edi, 0
	call	safe_tcgetattr
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	save_terminal_params, .-save_terminal_params
	.globl	restore_terminal_params
	.type	restore_terminal_params, @function
restore_terminal_params:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdx, old_termios[rip]
	mov	esi, 0
	mov	edi, 0
	call	safe_tcsetattr
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	restore_terminal_params, .-restore_terminal_params
	.section	.rodata
	.align 8
.LC2:
	.string	"stdin is not associated with an open terminal device: %s\n"
	.text
	.globl	verify_stdin_is_terminal
	.type	verify_stdin_is_terminal, @function
verify_stdin_is_terminal:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	edi, 0
	call	isatty@PLT
	test	eax, eax
	jne	.L11
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L11:
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	verify_stdin_is_terminal, .-verify_stdin_is_terminal
	.globl	switch_to_noncanonical_mode
	.type	switch_to_noncanonical_mode, @function
switch_to_noncanonical_mode:
.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, 80
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -80[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	safe_tcgetattr
	mov	DWORD PTR -80[rbp], 32
	mov	DWORD PTR -76[rbp], 0
	mov	DWORD PTR -68[rbp], 0
	lea	rax, -80[rbp]
	mov	rdx, rax
	mov	esi, 0
	mov	edi, 0
	call	safe_tcsetattr
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	switch_to_noncanonical_mode, .-switch_to_noncanonical_mode
	.section	.rodata
.LC3:
	.string	"Error reading stdin: %s\n"
	.text
	.globl	safe_read
	.type	safe_read, @function
safe_read:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -24[rbp], edx
	mov	eax, DWORD PTR -24[rbp]
	movsx	rdx, eax
	mov	rcx, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR -20[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L15
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L15:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	safe_read, .-safe_read
	.section	.rodata
.LC4:
	.string	"Error writing to stdout: %s\n"
	.text
	.globl	safe_write
	.type	safe_write, @function
safe_write:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -24[rbp], edx
	mov	eax, DWORD PTR -24[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], -1
	jne	.L18
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L18:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	safe_write, .-safe_write
	.section	.rodata
	.align 8
.LC5:
	.ascii	"Usage: ./lab1b-client --port=number [OPTION]...\nThe client "
	.ascii	"program will open a connection to a server\n(port specified "
	.ascii	"with the mandatory --port=command line parameter)\nrather th"
	.ascii	"an sending it directly to a shell. The client should then \n"
	.ascii	"send input from the keyboard"
	.string	" to the socket (while echoing to the display),\nand input from the socket to the display.\n\n\t--port=number   specify the port number for connection\n\t--log=filename  maintain a record of data sent over the socket\n\t--compress      compress the communication\n\t\t"
	.text
	.globl	getUsage
	.type	getUsage, @function
getUsage:
.LFB14:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rax, .LC5[rip]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	getUsage, .-getUsage
	.section	.rodata
.LC6:
	.string	"Erorr closing fd: %s\n"
	.text
	.globl	safe_close
	.type	safe_close, @function
safe_close:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	close@PLT
	cmp	eax, -1
	jne	.L24
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L24:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	safe_close, .-safe_close
	.section	.rodata
.LC7:
	.string	"Error killing a process: %s\n"
	.text
	.globl	safe_kill
	.type	safe_kill, @function
safe_kill:
.LFB16:
	.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 -8[rbp], esi
	mov	edx, DWORD PTR -8[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, edx
	mov	edi, eax
	call	kill@PLT
	cmp	eax, -1
	jne	.L27
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L27:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE16:
	.size	safe_kill, .-safe_kill
	.section	.rodata
.LC8:
	.string	"Error while polling: %s\n"
	.text
	.globl	safe_poll
	.type	safe_poll, @function
safe_poll:
.LFB17:
	.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	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	DWORD PTR -16[rbp], edx
	mov	eax, DWORD PTR -12[rbp]
	movsx	rcx, eax
	mov	edx, DWORD PTR -16[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	poll@PLT
	cmp	eax, -1
	jne	.L30
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L30:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE17:
	.size	safe_poll, .-safe_poll
	.globl	add_observer
	.type	add_observer, @function
add_observer:
.LFB18:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	eax, edx
	mov	WORD PTR -16[rbp], ax
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	mov	DWORD PTR [rax], edx
	mov	rax, QWORD PTR -8[rbp]
	movzx	edx, WORD PTR -16[rbp]
	mov	WORD PTR 4[rax], dx
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE18:
	.size	add_observer, .-add_observer
	.section	.rodata
.LC9:
	.string	"Error setting signal: %s\n"
	.text
	.globl	safe_signal
	.type	safe_signal, @function
safe_signal:
.LFB19:
	.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	QWORD PTR -16[rbp], rsi
	mov	rdx, QWORD PTR -16[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	signal@PLT
	cmp	rax, -1
	jne	.L34
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC9[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L34:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE19:
	.size	safe_signal, .-safe_signal
	.section	.rodata
	.align 8
.LC10:
	.string	"Error forking the process: %s\n"
	.text
	.globl	safe_fork
	.type	safe_fork, @function
safe_fork:
.LFB20:
	.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
	call	fork@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L36
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L36:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE20:
	.size	safe_fork, .-safe_fork
	.section	.rodata
.LC11:
	.string	"Error creating pipe: %s\n"
	.text
	.globl	safe_pipe
	.type	safe_pipe, @function
safe_pipe:
.LFB21:
	.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	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	pipe@PLT
	cmp	eax, -1
	jne	.L40
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC11[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L40:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE21:
	.size	safe_pipe, .-safe_pipe
	.section	.rodata
.LC12:
	.string	"Error opening socket: %s\n"
	.text
	.globl	safe_socket
	.type	safe_socket, @function
safe_socket:
.LFB22:
	.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	DWORD PTR -24[rbp], esi
	mov	DWORD PTR -28[rbp], edx
	mov	edx, DWORD PTR -28[rbp]
	mov	ecx, DWORD PTR -24[rbp]
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	socket@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L42
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC12[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L42:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE22:
	.size	safe_socket, .-safe_socket
	.section	.rodata
.LC13:
	.string	"Error finding the host: %s\n"
	.text
	.globl	safe_gethostbyname
	.type	safe_gethostbyname, @function
safe_gethostbyname:
.LFB23:
	.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	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	gethostbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L45
	call	__h_errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC13[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L45:
	mov	rax, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE23:
	.size	safe_gethostbyname, .-safe_gethostbyname
	.section	.rodata
	.align 8
.LC14:
	.string	"Error connecting to server: %s\n"
	.text
	.globl	safe_connect
	.type	safe_connect, @function
safe_connect:
.LFB24:
	.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	QWORD PTR -16[rbp], rsi
	mov	DWORD PTR -8[rbp], edx
	mov	edx, DWORD PTR -8[rbp]
	mov	rcx, QWORD PTR -16[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	cmp	eax, -1
	jne	.L49
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC14[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L49:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE24:
	.size	safe_connect, .-safe_connect
	.section	.rodata
.LC15:
	.string	"localhost"
	.text
	.globl	handle_socket
	.type	handle_socket, @function
handle_socket:
.LFB25:
	.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	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	safe_socket
	mov	DWORD PTR -44[rbp], eax
	lea	rdi, .LC15[rip]
	call	safe_gethostbyname
	mov	QWORD PTR -40[rbp], rax
	lea	rax, -32[rbp]
	mov	edx, 16
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	WORD PTR -32[rbp], 2
	mov	rax, QWORD PTR -40[rbp]
	mov	eax, DWORD PTR 20[rax]
	movsx	rdx, eax
	mov	rax, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR 24[rax]
	mov	rax, QWORD PTR [rax]
	lea	rcx, -32[rbp]
	add	rcx, 4
	mov	rsi, rax
	mov	rdi, rcx
	call	memcpy@PLT
	mov	eax, DWORD PTR port[rip]
	movzx	eax, ax
	mov	edi, eax
	call	htons@PLT
	mov	WORD PTR -30[rbp], ax
	lea	rcx, -32[rbp]
	mov	eax, DWORD PTR -44[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	safe_connect
	mov	eax, DWORD PTR -44[rbp]
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L52
	call	__stack_chk_fail@PLT
.L52:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE25:
	.size	handle_socket, .-handle_socket
	.globl	cleanup_deflate_stream
	.type	cleanup_deflate_stream, @function
cleanup_deflate_stream:
.LFB26:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, deflate_stream[rip]
	call	deflateEnd@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE26:
	.size	cleanup_deflate_stream, .-cleanup_deflate_stream
	.section	.rodata
.LC16:
	.string	"1.2.11"
	.align 8
.LC17:
	.string	"Error initializing deflate stream\n"
	.text
	.globl	safe_delfateInit
	.type	safe_delfateInit, @function
safe_delfateInit:
.LFB27:
	.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	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	esi, DWORD PTR -12[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, 112
	lea	rdx, .LC16[rip]
	mov	rdi, rax
	call	deflateInit_@PLT
	test	eax, eax
	je	.L56
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 34
	mov	esi, 1
	lea	rdi, .LC17[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L56:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE27:
	.size	safe_delfateInit, .-safe_delfateInit
	.globl	init_deflate_stream
	.type	init_deflate_stream, @function
init_deflate_stream:
.LFB28:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR deflate_stream[rip+64], 0
	mov	QWORD PTR deflate_stream[rip+72], 0
	mov	QWORD PTR deflate_stream[rip+80], 0
	mov	esi, -1
	lea	rdi, deflate_stream[rip]
	call	safe_delfateInit
	lea	rdi, cleanup_deflate_stream[rip]
	call	atexit@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE28:
	.size	init_deflate_stream, .-init_deflate_stream
	.globl	cleanup_inflate_stream
	.type	cleanup_inflate_stream, @function
cleanup_inflate_stream:
.LFB29:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, inflate_stream[rip]
	call	inflateEnd@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE29:
	.size	cleanup_inflate_stream, .-cleanup_inflate_stream
	.section	.rodata
	.align 8
.LC18:
	.string	"Error initializing inflate stream\n"
	.text
	.globl	safe_inflateInit
	.type	safe_inflateInit, @function
safe_inflateInit:
.LFB30:
	.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	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, 112
	lea	rsi, .LC16[rip]
	mov	rdi, rax
	call	inflateInit_@PLT
	test	eax, eax
	je	.L61
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 34
	mov	esi, 1
	lea	rdi, .LC18[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L61:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE30:
	.size	safe_inflateInit, .-safe_inflateInit
	.globl	init_inflate_stream
	.type	init_inflate_stream, @function
init_inflate_stream:
.LFB31:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR inflate_stream[rip+64], 0
	mov	QWORD PTR inflate_stream[rip+72], 0
	mov	QWORD PTR inflate_stream[rip+80], 0
	lea	rdi, inflate_stream[rip]
	call	safe_inflateInit
	lea	rdi, cleanup_inflate_stream[rip]
	call	atexit@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE31:
	.size	init_inflate_stream, .-init_inflate_stream
	.globl	init_compression_streams
	.type	init_compression_streams, @function
init_compression_streams:
.LFB32:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	eax, 0
	call	init_deflate_stream
	mov	eax, 0
	call	init_inflate_stream
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE32:
	.size	init_compression_streams, .-init_compression_streams
	.section	.rodata
.LC19:
	.string	"Error deflating data\n"
	.text
	.globl	safe_deflate
	.type	safe_deflate, @function
safe_deflate:
.LFB33:
	.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	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	edx, DWORD PTR -12[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	deflate@PLT
	test	eax, eax
	je	.L66
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 21
	mov	esi, 1
	lea	rdi, .LC19[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L66:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE33:
	.size	safe_deflate, .-safe_deflate
	.globl	simple_deflate
	.type	simple_deflate, @function
simple_deflate:
.LFB34:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 304
	mov	QWORD PTR -296[rbp], rdi
	mov	QWORD PTR -304[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -304[rbp]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR deflate_stream[rip+8], eax
	mov	rax, QWORD PTR -296[rbp]
	mov	QWORD PTR deflate_stream[rip], rax
	mov	DWORD PTR deflate_stream[rip+32], 256
	lea	rax, -272[rbp]
	mov	QWORD PTR deflate_stream[rip+24], rax
.L68:
	mov	esi, 2
	lea	rdi, deflate_stream[rip]
	call	safe_deflate
	mov	eax, DWORD PTR deflate_stream[rip+8]
	test	eax, eax
	jne	.L68
	mov	edx, DWORD PTR deflate_stream[rip+32]
	mov	eax, 256
	sub	eax, edx
	mov	edx, eax
	mov	rax, QWORD PTR -304[rbp]
	mov	DWORD PTR [rax], edx
	mov	DWORD PTR -276[rbp], 0
	jmp	.L69
.L70:
	mov	eax, DWORD PTR -276[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -296[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -276[rbp]
	cdqe
	movzx	eax, BYTE PTR -272[rbp+rax]
	mov	BYTE PTR [rdx], al
	add	DWORD PTR -276[rbp], 1
.L69:
	mov	rax, QWORD PTR -304[rbp]
	mov	eax, DWORD PTR [rax]
	cmp	DWORD PTR -276[rbp], eax
	jl	.L70
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L71
	call	__stack_chk_fail@PLT
.L71:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE34:
	.size	simple_deflate, .-simple_deflate
	.section	.rodata
.LC20:
	.string	"Error inflating data\n"
	.text
	.globl	safe_inflate
	.type	safe_inflate, @function
safe_inflate:
.LFB35:
	.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	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	edx, DWORD PTR -12[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	inflate@PLT
	test	eax, eax
	je	.L74
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 21
	mov	esi, 1
	lea	rdi, .LC20[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L74:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE35:
	.size	safe_inflate, .-safe_inflate
	.globl	simple_inflate
	.type	simple_inflate, @function
simple_inflate:
.LFB36:
	.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	QWORD PTR -2096[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -2096[rbp]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR inflate_stream[rip+8], eax
	mov	rax, QWORD PTR -2088[rbp]
	mov	QWORD PTR inflate_stream[rip], rax
	mov	DWORD PTR inflate_stream[rip+32], 2048
	lea	rax, -2064[rbp]
	mov	QWORD PTR inflate_stream[rip+24], rax
.L76:
	mov	esi, 2
	lea	rdi, inflate_stream[rip]
	call	safe_inflate
	mov	eax, DWORD PTR inflate_stream[rip+8]
	test	eax, eax
	jne	.L76
	mov	edx, DWORD PTR inflate_stream[rip+32]
	mov	eax, 2048
	sub	eax, edx
	mov	edx, eax
	mov	rax, QWORD PTR -2096[rbp]
	mov	DWORD PTR [rax], edx
	mov	DWORD PTR -2068[rbp], 0
	jmp	.L77
.L78:
	mov	eax, DWORD PTR -2068[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -2088[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -2068[rbp]
	cdqe
	movzx	eax, BYTE PTR -2064[rbp+rax]
	mov	BYTE PTR [rdx], al
	add	DWORD PTR -2068[rbp], 1
.L77:
	mov	rax, QWORD PTR -2096[rbp]
	mov	eax, DWORD PTR [rax]
	cmp	DWORD PTR -2068[rbp], eax
	jl	.L78
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L79
	call	__stack_chk_fail@PLT
.L79:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE36:
	.size	simple_inflate, .-simple_inflate
	.section	.rodata
.LC21:
	.string	"Error using dprintf: %s\n"
	.text
	.globl	simple_dprintf
	.type	simple_dprintf, @function
simple_dprintf:
.LFB37:
	.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	QWORD PTR -16[rbp], rsi
	mov	DWORD PTR -8[rbp], edx
	mov	edx, DWORD PTR -8[rbp]
	mov	rcx, QWORD PTR -16[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	rsi, rcx
	mov	edi, eax
	mov	eax, 0
	call	dprintf@PLT
	cmp	eax, -1
	jne	.L82
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC21[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L82:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE37:
	.size	simple_dprintf, .-simple_dprintf
	.section	.rodata
.LC22:
	.string	"SENT %d bytes: "
.LC23:
	.string	"\n"
	.text
	.globl	log_bytes_sent
	.type	log_bytes_sent, @function
log_bytes_sent:
.LFB38:
	.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	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	eax, DWORD PTR log_fd[rip]
	mov	edx, DWORD PTR -12[rbp]
	lea	rsi, .LC22[rip]
	mov	edi, eax
	call	simple_dprintf
	mov	eax, DWORD PTR log_fd[rip]
	mov	edx, DWORD PTR -12[rbp]
	mov	rcx, QWORD PTR -8[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	safe_write
	mov	eax, DWORD PTR log_fd[rip]
	mov	edx, 1
	lea	rsi, .LC23[rip]
	mov	edi, eax
	call	safe_write
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE38:
	.size	log_bytes_sent, .-log_bytes_sent
	.section	.rodata
.LC24:
	.string	"RECEIVED %d bytes: "
	.text
	.globl	log_bytes_received
	.type	log_bytes_received, @function
log_bytes_received:
.LFB39:
	.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	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	eax, DWORD PTR log_fd[rip]
	mov	edx, DWORD PTR -12[rbp]
	lea	rsi, .LC24[rip]
	mov	edi, eax
	call	simple_dprintf
	mov	eax, DWORD PTR log_fd[rip]
	mov	edx, DWORD PTR -12[rbp]
	mov	rcx, QWORD PTR -8[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	safe_write
	mov	eax, DWORD PTR log_fd[rip]
	mov	edx, 1
	lea	rsi, .LC23[rip]
	mov	edi, eax
	call	safe_write
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE39:
	.size	log_bytes_received, .-log_bytes_received
	.section	.rodata
.LC25:
	.string	"\r\n"
	.text
	.globl	safe_terminal_write
	.type	safe_terminal_write, @function
safe_terminal_write:
.LFB40:
	.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
	mov	DWORD PTR -4[rbp], 0
	jmp	.L86
.L90:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -32[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	cmp	al, 13
	je	.L87
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -32[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	cmp	al, 10
	jne	.L88
.L87:
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, 2
	lea	rsi, .LC25[rip]
	mov	edi, eax
	call	safe_write
	jmp	.L89
.L88:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -32[rbp]
	lea	rcx, [rdx+rax]
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, 1
	mov	rsi, rcx
	mov	edi, eax
	call	safe_write
.L89:
	add	DWORD PTR -4[rbp], 1
.L86:
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -24[rbp]
	jl	.L90
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE40:
	.size	safe_terminal_write, .-safe_terminal_write
	.globl	handle_read_from_keyboard
	.type	handle_read_from_keyboard, @function
handle_read_from_keyboard:
.LFB41:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 304
	mov	DWORD PTR -292[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -272[rbp]
	mov	edx, 256
	mov	rsi, rax
	mov	edi, 0
	call	safe_read
	mov	DWORD PTR -276[rbp], eax
	mov	edx, DWORD PTR -276[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rax
	mov	edi, 1
	call	safe_terminal_write
	mov	eax, DWORD PTR compress_flag[rip]
	test	eax, eax
	je	.L92
	lea	rdx, -276[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	simple_deflate
.L92:
	mov	eax, DWORD PTR log_flag[rip]
	test	eax, eax
	je	.L93
	mov	edx, DWORD PTR -276[rbp]
	lea	rax, -272[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	log_bytes_sent
.L93:
	mov	edx, DWORD PTR -276[rbp]
	lea	rcx, -272[rbp]
	mov	eax, DWORD PTR -292[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	safe_write
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L94
	call	__stack_chk_fail@PLT
.L94:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE41:
	.size	handle_read_from_keyboard, .-handle_read_from_keyboard
	.globl	handle_read_from_socket
	.type	handle_read_from_socket, @function
handle_read_from_socket:
.LFB42:
	.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	DWORD PTR -2084[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rcx, -2064[rbp]
	mov	eax, DWORD PTR -2084[rbp]
	mov	edx, 256
	mov	rsi, rcx
	mov	edi, eax
	call	safe_read
	mov	DWORD PTR -2068[rbp], eax
	mov	eax, DWORD PTR -2068[rbp]
	test	eax, eax
	jne	.L96
	mov	eax, DWORD PTR -2068[rbp]
	jmp	.L100
.L96:
	mov	eax, DWORD PTR log_flag[rip]
	test	eax, eax
	je	.L98
	mov	edx, DWORD PTR -2068[rbp]
	lea	rax, -2064[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	log_bytes_received
.L98:
	mov	eax, DWORD PTR compress_flag[rip]
	test	eax, eax
	je	.L99
	lea	rdx, -2068[rbp]
	lea	rax, -2064[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	simple_inflate
.L99:
	mov	edx, DWORD PTR -2068[rbp]
	lea	rax, -2064[rbp]
	mov	rsi, rax
	mov	edi, 1
	call	safe_terminal_write
	mov	eax, DWORD PTR -2068[rbp]
.L100:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L101
	call	__stack_chk_fail@PLT
.L101:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE42:
	.size	handle_read_from_socket, .-handle_read_from_socket
	.globl	read_leftover
	.type	read_leftover, @function
read_leftover:
.LFB43:
	.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	DWORD PTR -2084[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	jmp	.L103
.L106:
	mov	eax, DWORD PTR log_flag[rip]
	test	eax, eax
	je	.L104
	mov	edx, DWORD PTR -2068[rbp]
	lea	rax, -2064[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	log_bytes_received
.L104:
	mov	eax, DWORD PTR compress_flag[rip]
	test	eax, eax
	je	.L105
	lea	rdx, -2068[rbp]
	lea	rax, -2064[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	simple_inflate
.L105:
	mov	edx, DWORD PTR -2068[rbp]
	lea	rax, -2064[rbp]
	mov	rsi, rax
	mov	edi, 1
	call	safe_terminal_write
.L103:
	lea	rcx, -2064[rbp]
	mov	eax, DWORD PTR -2084[rbp]
	mov	edx, 256
	mov	rsi, rcx
	mov	edi, eax
	call	safe_read
	mov	DWORD PTR -2068[rbp], eax
	mov	eax, DWORD PTR -2068[rbp]
	test	eax, eax
	jne	.L106
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L107
	call	__stack_chk_fail@PLT
.L107:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE43:
	.size	read_leftover, .-read_leftover
	.section	.rodata
.LC26:
	.string	"stdin POLLERR detected: %s\n"
.LC27:
	.string	"socket POLLERR detected: %s\n"
	.text
	.globl	handle_port_option
	.type	handle_port_option, @function
handle_port_option:
.LFB44:
	.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	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	eax, 0
	call	handle_socket
	mov	DWORD PTR -40[rbp], eax
	lea	rax, -32[rbp]
	mov	edx, 25
	mov	esi, 0
	mov	rdi, rax
	call	add_observer
	mov	eax, DWORD PTR -40[rbp]
	lea	rdx, -32[rbp]
	lea	rcx, 8[rdx]
	mov	edx, 25
	mov	esi, eax
	mov	rdi, rcx
	call	add_observer
.L116:
	lea	rax, -32[rbp]
	mov	edx, -1
	mov	esi, 2
	mov	rdi, rax
	call	safe_poll
	movzx	eax, WORD PTR -26[rbp]
	cwde
	and	eax, 1
	test	eax, eax
	je	.L109
	mov	eax, DWORD PTR -40[rbp]
	mov	edi, eax
	call	handle_read_from_keyboard
.L109:
	movzx	eax, WORD PTR -18[rbp]
	cwde
	and	eax, 1
	test	eax, eax
	je	.L110
	mov	eax, DWORD PTR -40[rbp]
	mov	edi, eax
	call	handle_read_from_socket
	mov	DWORD PTR -36[rbp], eax
	cmp	DWORD PTR -36[rbp], 0
	je	.L119
.L110:
	movzx	eax, WORD PTR -26[rbp]
	cwde
	and	eax, 16
	test	eax, eax
	jne	.L112
	movzx	eax, WORD PTR -18[rbp]
	cwde
	and	eax, 16
	test	eax, eax
	je	.L113
.L112:
	mov	eax, DWORD PTR -40[rbp]
	mov	edi, eax
	call	read_leftover
	jmp	.L108
.L113:
	movzx	eax, WORD PTR -26[rbp]
	cwde
	and	eax, 8
	test	eax, eax
	je	.L114
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC26[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L108
.L114:
	movzx	eax, WORD PTR -18[rbp]
	cwde
	and	eax, 8
	test	eax, eax
	je	.L116
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC27[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L108
.L119:
	nop
.L108:
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L118
	call	__stack_chk_fail@PLT
.L118:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE44:
	.size	handle_port_option, .-handle_port_option
	.section	.rodata
.LC28:
	.string	"Error creating a file: %s\n"
	.text
	.globl	safe_creat
	.type	safe_creat, @function
safe_creat:
.LFB45:
	.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
	mov	edx, DWORD PTR -28[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	creat@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L121
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC28[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L121:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE45:
	.size	safe_creat, .-safe_creat
	.section	.rodata
.LC29:
	.string	"port"
.LC30:
	.string	"log"
.LC31:
	.string	"compress"
.LC32:
	.string	""
	.align 8
.LC33:
	.string	"Unrecognized argument detected\n%s\n"
.LC34:
	.string	"--port option is mandatory\n"
	.text
	.globl	support_options
	.type	support_options, @function
support_options:
.LFB46:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 176
	mov	DWORD PTR -164[rbp], edi
	mov	QWORD PTR -176[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, .LC29[rip]
	mov	QWORD PTR -144[rbp], rax
	mov	DWORD PTR -136[rbp], 1
	mov	QWORD PTR -128[rbp], 0
	mov	DWORD PTR -120[rbp], 112
	lea	rax, .LC30[rip]
	mov	QWORD PTR -112[rbp], rax
	mov	DWORD PTR -104[rbp], 1
	mov	QWORD PTR -96[rbp], 0
	mov	DWORD PTR -88[rbp], 108
	lea	rax, .LC31[rip]
	mov	QWORD PTR -80[rbp], rax
	mov	DWORD PTR -72[rbp], 0
	mov	QWORD PTR -64[rbp], 0
	mov	DWORD PTR -56[rbp], 99
	mov	QWORD PTR -48[rbp], 0
	mov	DWORD PTR -40[rbp], 0
	mov	QWORD PTR -32[rbp], 0
	mov	DWORD PTR -24[rbp], 0
.L131:
	lea	rdx, -144[rbp]
	mov	rsi, QWORD PTR -176[rbp]
	mov	eax, DWORD PTR -164[rbp]
	mov	r8d, 0
	mov	rcx, rdx
	lea	rdx, .LC32[rip]
	mov	edi, eax
	call	getopt_long@PLT
	mov	DWORD PTR -148[rbp], eax
	cmp	DWORD PTR -148[rbp], -1
	je	.L135
	cmp	DWORD PTR -148[rbp], 112
	je	.L126
	cmp	DWORD PTR -148[rbp], 112
	jg	.L127
	cmp	DWORD PTR -148[rbp], 99
	je	.L128
	cmp	DWORD PTR -148[rbp], 108
	je	.L129
	jmp	.L127
.L126:
	mov	DWORD PTR port_flag[rip], 1
	mov	rax, QWORD PTR optarg[rip]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR port[rip], eax
	jmp	.L130
.L129:
	mov	DWORD PTR log_flag[rip], 1
	mov	rax, QWORD PTR optarg[rip]
	mov	esi, 420
	mov	rdi, rax
	call	safe_creat
	mov	DWORD PTR log_fd[rip], eax
	jmp	.L130
.L128:
	mov	DWORD PTR compress_flag[rip], 1
	mov	eax, 0
	call	init_compression_streams
	jmp	.L130
.L127:
	mov	eax, 0
	call	getUsage
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC33[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L130:
	jmp	.L131
.L135:
	nop
	mov	eax, DWORD PTR port_flag[rip]
	test	eax, eax
	jne	.L136
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 27
	mov	esi, 1
	lea	rdi, .LC34[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L136:
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L133
	call	__stack_chk_fail@PLT
.L133:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE46:
	.size	support_options, .-support_options
	.globl	main
	.type	main, @function
main:
.LFB47:
	.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	QWORD PTR -16[rbp], rsi
	mov	rdx, QWORD PTR -16[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	support_options
	mov	eax, 0
	call	save_terminal_params
	lea	rdi, restore_terminal_params[rip]
	call	atexit@PLT
	mov	eax, 0
	call	verify_stdin_is_terminal
	mov	eax, 0
	call	switch_to_noncanonical_mode
	mov	eax, 0
	call	handle_port_option
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE47:
	.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	"484654.c"
	.section	.rodata
	.align	2
.LC0:
	.ascii	"port\000"
	.align	2
.LC1:
	.ascii	"log\000"
	.align	2
.LC2:
	.ascii	"compress\000"
	.text
	.comm	old_termios,60,4
	.global	port_flag
	.bss
	.align	2
	.type	port_flag, %object
	.size	port_flag, 4
port_flag:
	.space	4
	.global	log_flag
	.align	2
	.type	log_flag, %object
	.size	log_flag, 4
log_flag:
	.space	4
	.global	compress_flag
	.align	2
	.type	compress_flag, %object
	.size	compress_flag, 4
compress_flag:
	.space	4
	.global	port
	.data
	.align	2
	.type	port, %object
	.size	port, 4
port:
	.word	-1
	.global	log_fd
	.align	2
	.type	log_fd, %object
	.size	log_fd, 4
log_fd:
	.word	-1
	.comm	deflate_stream,56,4
	.comm	inflate_stream,56,4
	.section	.rodata
	.align	2
.LC4:
	.ascii	"Error getting terminal parameters: %s\012\000"
	.text
	.align	2
	.global	safe_tcgetattr
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_tcgetattr, %function
safe_tcgetattr:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	tcgetattr
	mov	r3, r0
	cmn	r3, #1
	bne	.L3
	ldr	r3, .L4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L4+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L3:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L5:
	.align	2
.L4:
	.word	stderr
	.word	.LC4
	.size	safe_tcgetattr, .-safe_tcgetattr
	.section	.rodata
	.align	2
.LC5:
	.ascii	"Error setting terminal parameters: %s\012\000"
	.text
	.align	2
	.global	safe_tcsetattr
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_tcsetattr, %function
safe_tcsetattr:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	tcsetattr
	mov	r3, r0
	cmn	r3, #1
	bne	.L8
	ldr	r3, .L9
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L9+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L8:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L10:
	.align	2
.L9:
	.word	stderr
	.word	.LC5
	.size	safe_tcsetattr, .-safe_tcsetattr
	.align	2
	.global	save_terminal_params
	.syntax unified
	.arm
	.fpu softvfp
	.type	save_terminal_params, %function
save_terminal_params:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r1, .L12
	mov	r0, #0
	bl	safe_tcgetattr
	nop
	pop	{fp, pc}
.L13:
	.align	2
.L12:
	.word	old_termios
	.size	save_terminal_params, .-save_terminal_params
	.align	2
	.global	restore_terminal_params
	.syntax unified
	.arm
	.fpu softvfp
	.type	restore_terminal_params, %function
restore_terminal_params:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r2, .L15
	mov	r1, #0
	mov	r0, #0
	bl	safe_tcsetattr
	nop
	pop	{fp, pc}
.L16:
	.align	2
.L15:
	.word	old_termios
	.size	restore_terminal_params, .-restore_terminal_params
	.section	.rodata
	.align	2
.LC6:
	.ascii	"stdin is not associated with an open terminal devic"
	.ascii	"e: %s\012\000"
	.text
	.align	2
	.global	verify_stdin_is_terminal
	.syntax unified
	.arm
	.fpu softvfp
	.type	verify_stdin_is_terminal, %function
verify_stdin_is_terminal:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	mov	r0, #0
	bl	isatty
	mov	r3, r0
	cmp	r3, #0
	bne	.L19
	ldr	r3, .L20
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L20+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L19:
	nop
	pop	{r4, r5, fp, pc}
.L21:
	.align	2
.L20:
	.word	stderr
	.word	.LC6
	.size	verify_stdin_is_terminal, .-verify_stdin_is_terminal
	.section	.rodata
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	switch_to_noncanonical_mode
	.syntax unified
	.arm
	.fpu softvfp
	.type	switch_to_noncanonical_mode, %function
switch_to_noncanonical_mode:
	@ args = 0, pretend = 0, frame = 64
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #64
	ldr	r3, .L24
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #68
	mov	r1, r3
	mov	r0, #0
	bl	safe_tcgetattr
	mov	r3, #32
	str	r3, [fp, #-68]
	mov	r3, #0
	str	r3, [fp, #-64]
	mov	r3, #0
	str	r3, [fp, #-56]
	sub	r3, fp, #68
	mov	r2, r3
	mov	r1, #0
	mov	r0, #0
	bl	safe_tcsetattr
	nop
	ldr	r3, .L24
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L23
	bl	__stack_chk_fail
.L23:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L25:
	.align	2
.L24:
	.word	.LC7
	.size	switch_to_noncanonical_mode, .-switch_to_noncanonical_mode
	.section	.rodata
	.align	2
.LC8:
	.ascii	"Error reading stdin: %s\012\000"
	.text
	.align	2
	.global	safe_read
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_read, %function
safe_read:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	ldr	r3, [fp, #-32]
	mov	r2, r3
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	read
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L27
	ldr	r3, .L29
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L29+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L27:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L30:
	.align	2
.L29:
	.word	stderr
	.word	.LC8
	.size	safe_read, .-safe_read
	.section	.rodata
	.align	2
.LC9:
	.ascii	"Error writing to stdout: %s\012\000"
	.text
	.align	2
	.global	safe_write
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_write, %function
safe_write:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	ldr	r3, [fp, #-32]
	mov	r2, r3
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	write
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L32
	ldr	r3, .L34
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L34+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L32:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L35:
	.align	2
.L34:
	.word	stderr
	.word	.LC9
	.size	safe_write, .-safe_write
	.section	.rodata
	.align	2
.LC10:
	.ascii	"Usage: ./lab1b-client --port=number [OPTION]...\012"
	.ascii	"The client program will open a connection to a serv"
	.ascii	"er\012(port specified with the mandatory --port=com"
	.ascii	"mand line parameter)\012rather than sending it dire"
	.ascii	"ctly to a shell. The client should then \012send in"
	.ascii	"put from the keyboard to the socket (while echoing "
	.ascii	"to the display),\012and input from the socket to th"
	.ascii	"e display.\012\012\011--port=number   specify the p"
	.ascii	"ort number for connection\012\011--log=filename  ma"
	.ascii	"intain a record of data sent over the socket\012\011"
	.ascii	"--compress      compress the communication\012\011\011"
	.ascii	"\000"
	.text
	.align	2
	.global	getUsage
	.syntax unified
	.arm
	.fpu softvfp
	.type	getUsage, %function
getUsage:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	ldr	r3, .L38
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L39:
	.align	2
.L38:
	.word	.LC10
	.size	getUsage, .-getUsage
	.section	.rodata
	.align	2
.LC11:
	.ascii	"Erorr closing fd: %s\012\000"
	.text
	.align	2
	.global	safe_close
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_close, %function
safe_close:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	str	r0, [fp, #-16]
	ldr	r0, [fp, #-16]
	bl	close
	mov	r3, r0
	cmn	r3, #1
	bne	.L42
	ldr	r3, .L43
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L43+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L42:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L44:
	.align	2
.L43:
	.word	stderr
	.word	.LC11
	.size	safe_close, .-safe_close
	.section	.rodata
	.align	2
.LC12:
	.ascii	"Error killing a process: %s\012\000"
	.text
	.align	2
	.global	safe_kill
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_kill, %function
safe_kill:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	kill
	mov	r3, r0
	cmn	r3, #1
	bne	.L47
	ldr	r3, .L48
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L48+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L47:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L49:
	.align	2
.L48:
	.word	stderr
	.word	.LC12
	.size	safe_kill, .-safe_kill
	.section	.rodata
	.align	2
.LC13:
	.ascii	"Error while polling: %s\012\000"
	.text
	.align	2
	.global	safe_poll
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_poll, %function
safe_poll:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	ldr	r3, [fp, #-20]
	ldr	r2, [fp, #-24]
	mov	r1, r3
	ldr	r0, [fp, #-16]
	bl	poll
	mov	r3, r0
	cmn	r3, #1
	bne	.L52
	ldr	r3, .L53
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L53+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L52:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L54:
	.align	2
.L53:
	.word	stderr
	.word	.LC13
	.size	safe_poll, .-safe_poll
	.align	2
	.global	add_observer
	.syntax unified
	.arm
	.fpu softvfp
	.type	add_observer, %function
add_observer:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	mov	r3, r2
	strh	r3, [fp, #-14]	@ movhi
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	ldrh	r2, [fp, #-14]	@ movhi
	strh	r2, [r3, #4]	@ movhi
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	add_observer, .-add_observer
	.section	.rodata
	.align	2
.LC14:
	.ascii	"Error setting signal: %s\012\000"
	.text
	.align	2
	.global	safe_signal
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_signal, %function
safe_signal:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	signal
	mov	r3, r0
	cmn	r3, #1
	bne	.L58
	ldr	r3, .L59
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L59+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L58:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L60:
	.align	2
.L59:
	.word	stderr
	.word	.LC14
	.size	safe_signal, .-safe_signal
	.section	.rodata
	.align	2
.LC15:
	.ascii	"Error forking the process: %s\012\000"
	.text
	.align	2
	.global	safe_fork
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_fork, %function
safe_fork:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L62
	ldr	r3, .L64
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L64+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L62:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L65:
	.align	2
.L64:
	.word	stderr
	.word	.LC15
	.size	safe_fork, .-safe_fork
	.section	.rodata
	.align	2
.LC16:
	.ascii	"Error creating pipe: %s\012\000"
	.text
	.align	2
	.global	safe_pipe
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_pipe, %function
safe_pipe:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	str	r0, [fp, #-16]
	ldr	r0, [fp, #-16]
	bl	pipe
	mov	r3, r0
	cmn	r3, #1
	bne	.L68
	ldr	r3, .L69
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L69+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L68:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L70:
	.align	2
.L69:
	.word	stderr
	.word	.LC16
	.size	safe_pipe, .-safe_pipe
	.section	.rodata
	.align	2
.LC17:
	.ascii	"Error opening socket: %s\012\000"
	.text
	.align	2
	.global	safe_socket
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_socket, %function
safe_socket:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	ldr	r2, [fp, #-32]
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	socket
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L72
	ldr	r3, .L74
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L74+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L72:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L75:
	.align	2
.L74:
	.word	stderr
	.word	.LC17
	.size	safe_socket, .-safe_socket
	.section	.rodata
	.align	2
.LC18:
	.ascii	"Error finding the host: %s\012\000"
	.text
	.align	2
	.global	safe_gethostbyname
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_gethostbyname, %function
safe_gethostbyname:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-24]
	ldr	r0, [fp, #-24]
	bl	gethostbyname
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L77
	ldr	r3, .L79
	ldr	r4, [r3]
	bl	__h_errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L79+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L77:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L80:
	.align	2
.L79:
	.word	stderr
	.word	.LC18
	.size	safe_gethostbyname, .-safe_gethostbyname
	.section	.rodata
	.align	2
.LC19:
	.ascii	"Error connecting to server: %s\012\000"
	.text
	.align	2
	.global	safe_connect
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_connect, %function
safe_connect:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	connect
	mov	r3, r0
	cmn	r3, #1
	bne	.L83
	ldr	r3, .L84
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L84+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L83:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L85:
	.align	2
.L84:
	.word	stderr
	.word	.LC19
	.size	safe_connect, .-safe_connect
	.section	.rodata
	.align	2
.LC20:
	.ascii	"localhost\000"
	.align	2
.LC21:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	handle_socket
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_socket, %function
handle_socket:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	ldr	r3, .L89
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	safe_socket
	str	r0, [fp, #-32]
	ldr	r0, .L89+4
	bl	safe_gethostbyname
	str	r0, [fp, #-28]
	sub	r3, fp, #24
	mov	r2, #16
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #2
	strh	r3, [fp, #-24]	@ movhi
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #16]
	ldr	r1, [r3]
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #12]
	mov	r2, r3
	sub	r3, fp, #24
	add	r3, r3, #4
	mov	r0, r3
	bl	memcpy
	ldr	r3, .L89+8
	ldr	r3, [r3]
	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	safe_connect
	ldr	r3, [fp, #-32]
	ldr	r2, .L89
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L88
	bl	__stack_chk_fail
.L88:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L90:
	.align	2
.L89:
	.word	.LC21
	.word	.LC20
	.word	port
	.size	handle_socket, .-handle_socket
	.align	2
	.global	cleanup_deflate_stream
	.syntax unified
	.arm
	.fpu softvfp
	.type	cleanup_deflate_stream, %function
cleanup_deflate_stream:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L92
	bl	deflateEnd
	nop
	pop	{fp, pc}
.L93:
	.align	2
.L92:
	.word	deflate_stream
	.size	cleanup_deflate_stream, .-cleanup_deflate_stream
	.section	.rodata
	.align	2
.LC22:
	.ascii	"1.2.11\000"
	.align	2
.LC23:
	.ascii	"Error initializing deflate stream\012\000"
	.text
	.align	2
	.global	safe_delfateInit
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_delfateInit, %function
safe_delfateInit:
	@ 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]
	str	r1, [fp, #-12]
	mov	r3, #56
	ldr	r2, .L97
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-8]
	bl	deflateInit_
	mov	r3, r0
	cmp	r3, #0
	beq	.L96
	ldr	r3, .L97+4
	ldr	r3, [r3]
	mov	r2, #34
	mov	r1, #1
	ldr	r0, .L97+8
	bl	fwrite
	mov	r0, #1
	bl	exit
.L96:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L98:
	.align	2
.L97:
	.word	.LC22
	.word	stderr
	.word	.LC23
	.size	safe_delfateInit, .-safe_delfateInit
	.align	2
	.global	init_deflate_stream
	.syntax unified
	.arm
	.fpu softvfp
	.type	init_deflate_stream, %function
init_deflate_stream:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r3, .L100
	mov	r2, #0
	str	r2, [r3, #32]
	ldr	r3, .L100
	mov	r2, #0
	str	r2, [r3, #36]
	ldr	r3, .L100
	mov	r2, #0
	str	r2, [r3, #40]
	mvn	r1, #0
	ldr	r0, .L100
	bl	safe_delfateInit
	ldr	r0, .L100+4
	bl	atexit
	nop
	pop	{fp, pc}
.L101:
	.align	2
.L100:
	.word	deflate_stream
	.word	cleanup_deflate_stream
	.size	init_deflate_stream, .-init_deflate_stream
	.align	2
	.global	cleanup_inflate_stream
	.syntax unified
	.arm
	.fpu softvfp
	.type	cleanup_inflate_stream, %function
cleanup_inflate_stream:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L103
	bl	inflateEnd
	nop
	pop	{fp, pc}
.L104:
	.align	2
.L103:
	.word	inflate_stream
	.size	cleanup_inflate_stream, .-cleanup_inflate_stream
	.section	.rodata
	.align	2
.LC24:
	.ascii	"Error initializing inflate stream\012\000"
	.text
	.align	2
	.global	safe_inflateInit
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_inflateInit, %function
safe_inflateInit:
	@ 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]
	mov	r2, #56
	ldr	r1, .L108
	ldr	r0, [fp, #-8]
	bl	inflateInit_
	mov	r3, r0
	cmp	r3, #0
	beq	.L107
	ldr	r3, .L108+4
	ldr	r3, [r3]
	mov	r2, #34
	mov	r1, #1
	ldr	r0, .L108+8
	bl	fwrite
	mov	r0, #1
	bl	exit
.L107:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L109:
	.align	2
.L108:
	.word	.LC22
	.word	stderr
	.word	.LC24
	.size	safe_inflateInit, .-safe_inflateInit
	.align	2
	.global	init_inflate_stream
	.syntax unified
	.arm
	.fpu softvfp
	.type	init_inflate_stream, %function
init_inflate_stream:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r3, .L111
	mov	r2, #0
	str	r2, [r3, #32]
	ldr	r3, .L111
	mov	r2, #0
	str	r2, [r3, #36]
	ldr	r3, .L111
	mov	r2, #0
	str	r2, [r3, #40]
	ldr	r0, .L111
	bl	safe_inflateInit
	ldr	r0, .L111+4
	bl	atexit
	nop
	pop	{fp, pc}
.L112:
	.align	2
.L111:
	.word	inflate_stream
	.word	cleanup_inflate_stream
	.size	init_inflate_stream, .-init_inflate_stream
	.align	2
	.global	init_compression_streams
	.syntax unified
	.arm
	.fpu softvfp
	.type	init_compression_streams, %function
init_compression_streams:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	bl	init_deflate_stream
	bl	init_inflate_stream
	nop
	pop	{fp, pc}
	.size	init_compression_streams, .-init_compression_streams
	.section	.rodata
	.align	2
.LC25:
	.ascii	"Error deflating data\012\000"
	.text
	.align	2
	.global	safe_deflate
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_deflate, %function
safe_deflate:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-8]
	bl	deflate
	mov	r3, r0
	cmp	r3, #0
	beq	.L116
	ldr	r3, .L117
	ldr	r3, [r3]
	mov	r2, #21
	mov	r1, #1
	ldr	r0, .L117+4
	bl	fwrite
	mov	r0, #1
	bl	exit
.L116:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L118:
	.align	2
.L117:
	.word	stderr
	.word	.LC25
	.size	safe_deflate, .-safe_deflate
	.section	.rodata
	.align	2
.LC26:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	simple_deflate
	.syntax unified
	.arm
	.fpu softvfp
	.type	simple_deflate, %function
simple_deflate:
	@ args = 0, pretend = 0, frame = 272
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #272
	str	r0, [fp, #-272]
	str	r1, [fp, #-276]
	ldr	r3, .L124
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-276]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, .L124+4
	str	r2, [r3, #4]
	ldr	r2, .L124+4
	ldr	r3, [fp, #-272]
	str	r3, [r2]
	ldr	r3, .L124+4
	mov	r2, #256
	str	r2, [r3, #16]
	ldr	r2, .L124+4
	sub	r3, fp, #264
	str	r3, [r2, #12]
.L120:
	mov	r1, #2
	ldr	r0, .L124+4
	bl	safe_deflate
	ldr	r3, .L124+4
	ldr	r3, [r3, #4]
	cmp	r3, #0
	bne	.L120
	ldr	r3, .L124+4
	ldr	r3, [r3, #16]
	rsb	r3, r3, #256
	mov	r2, r3
	ldr	r3, [fp, #-276]
	str	r2, [r3]
	mov	r3, #0
	str	r3, [fp, #-268]
	b	.L121
.L122:
	ldr	r3, [fp, #-268]
	ldr	r2, [fp, #-272]
	add	r3, r2, r3
	sub	r1, fp, #264
	ldr	r2, [fp, #-268]
	add	r2, r1, r2
	ldrb	r2, [r2]	@ zero_extendqisi2
	strb	r2, [r3]
	ldr	r3, [fp, #-268]
	add	r3, r3, #1
	str	r3, [fp, #-268]
.L121:
	ldr	r3, [fp, #-276]
	ldr	r3, [r3]
	ldr	r2, [fp, #-268]
	cmp	r2, r3
	blt	.L122
	nop
	ldr	r3, .L124
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L123
	bl	__stack_chk_fail
.L123:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L125:
	.align	2
.L124:
	.word	.LC26
	.word	deflate_stream
	.size	simple_deflate, .-simple_deflate
	.section	.rodata
	.align	2
.LC27:
	.ascii	"Error inflating data\012\000"
	.text
	.align	2
	.global	safe_inflate
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_inflate, %function
safe_inflate:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-8]
	bl	inflate
	mov	r3, r0
	cmp	r3, #0
	beq	.L128
	ldr	r3, .L129
	ldr	r3, [r3]
	mov	r2, #21
	mov	r1, #1
	ldr	r0, .L129+4
	bl	fwrite
	mov	r0, #1
	bl	exit
.L128:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L130:
	.align	2
.L129:
	.word	stderr
	.word	.LC27
	.size	safe_inflate, .-safe_inflate
	.section	.rodata
	.align	2
.LC28:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	simple_inflate
	.syntax unified
	.arm
	.fpu softvfp
	.type	simple_inflate, %function
simple_inflate:
	@ args = 0, pretend = 0, frame = 2064
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2064
	str	r0, [fp, #-2064]
	str	r1, [fp, #-2068]
	ldr	r3, .L136
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-2068]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, .L136+4
	str	r2, [r3, #4]
	ldr	r2, .L136+4
	ldr	r3, [fp, #-2064]
	str	r3, [r2]
	ldr	r3, .L136+4
	mov	r2, #2048
	str	r2, [r3, #16]
	ldr	r2, .L136+4
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	str	r3, [r2, #12]
.L132:
	mov	r1, #2
	ldr	r0, .L136+4
	bl	safe_inflate
	ldr	r3, .L136+4
	ldr	r3, [r3, #4]
	cmp	r3, #0
	bne	.L132
	ldr	r3, .L136+4
	ldr	r3, [r3, #16]
	rsb	r3, r3, #2048
	mov	r2, r3
	ldr	r3, [fp, #-2068]
	str	r2, [r3]
	mov	r3, #0
	str	r3, [fp, #-2060]
	b	.L133
.L134:
	ldr	r3, [fp, #-2060]
	ldr	r2, [fp, #-2064]
	add	r2, r2, r3
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r1, [fp, #-2060]
	add	r3, r3, r1
	ldrb	r3, [r3]	@ zero_extendqisi2
	strb	r3, [r2]
	ldr	r3, [fp, #-2060]
	add	r3, r3, #1
	str	r3, [fp, #-2060]
.L133:
	ldr	r3, [fp, #-2068]
	ldr	r3, [r3]
	ldr	r2, [fp, #-2060]
	cmp	r2, r3
	blt	.L134
	nop
	ldr	r3, .L136
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L135
	bl	__stack_chk_fail
.L135:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L137:
	.align	2
.L136:
	.word	.LC28
	.word	inflate_stream
	.size	simple_inflate, .-simple_inflate
	.section	.rodata
	.align	2
.LC29:
	.ascii	"Error using dprintf: %s\012\000"
	.text
	.align	2
	.global	simple_dprintf
	.syntax unified
	.arm
	.fpu softvfp
	.type	simple_dprintf, %function
simple_dprintf:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	dprintf
	mov	r3, r0
	cmn	r3, #1
	bne	.L140
	ldr	r3, .L141
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L141+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L140:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L142:
	.align	2
.L141:
	.word	stderr
	.word	.LC29
	.size	simple_dprintf, .-simple_dprintf
	.section	.rodata
	.align	2
.LC30:
	.ascii	"SENT %d bytes: \000"
	.align	2
.LC31:
	.ascii	"\012\000"
	.text
	.align	2
	.global	log_bytes_sent
	.syntax unified
	.arm
	.fpu softvfp
	.type	log_bytes_sent, %function
log_bytes_sent:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r3, .L144
	ldr	r3, [r3]
	ldr	r2, [fp, #-12]
	ldr	r1, .L144+4
	mov	r0, r3
	bl	simple_dprintf
	ldr	r3, .L144
	ldr	r3, [r3]
	ldr	r2, [fp, #-12]
	ldr	r1, [fp, #-8]
	mov	r0, r3
	bl	safe_write
	ldr	r3, .L144
	ldr	r3, [r3]
	mov	r2, #1
	ldr	r1, .L144+8
	mov	r0, r3
	bl	safe_write
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L145:
	.align	2
.L144:
	.word	log_fd
	.word	.LC30
	.word	.LC31
	.size	log_bytes_sent, .-log_bytes_sent
	.section	.rodata
	.align	2
.LC32:
	.ascii	"RECEIVED %d bytes: \000"
	.text
	.align	2
	.global	log_bytes_received
	.syntax unified
	.arm
	.fpu softvfp
	.type	log_bytes_received, %function
log_bytes_received:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r3, .L147
	ldr	r3, [r3]
	ldr	r2, [fp, #-12]
	ldr	r1, .L147+4
	mov	r0, r3
	bl	simple_dprintf
	ldr	r3, .L147
	ldr	r3, [r3]
	ldr	r2, [fp, #-12]
	ldr	r1, [fp, #-8]
	mov	r0, r3
	bl	safe_write
	ldr	r3, .L147
	ldr	r3, [r3]
	mov	r2, #1
	ldr	r1, .L147+8
	mov	r0, r3
	bl	safe_write
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L148:
	.align	2
.L147:
	.word	log_fd
	.word	.LC32
	.word	.LC31
	.size	log_bytes_received, .-log_bytes_received
	.section	.rodata
	.align	2
.LC33:
	.ascii	"\015\012\000"
	.text
	.align	2
	.global	safe_terminal_write
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_terminal_write, %function
safe_terminal_write:
	@ 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]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L150
.L154:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #13
	beq	.L151
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	bne	.L152
.L151:
	mov	r2, #2
	ldr	r1, .L155
	ldr	r0, [fp, #-16]
	bl	safe_write
	b	.L153
.L152:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	add	r3, r2, r3
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-16]
	bl	safe_write
.L153:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L150:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-24]
	cmp	r2, r3
	blt	.L154
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L156:
	.align	2
.L155:
	.word	.LC33
	.size	safe_terminal_write, .-safe_terminal_write
	.section	.rodata
	.align	2
.LC34:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	handle_read_from_keyboard
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_read_from_keyboard, %function
handle_read_from_keyboard:
	@ args = 0, pretend = 0, frame = 272
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #272
	str	r0, [fp, #-272]
	ldr	r3, .L161
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #264
	mov	r2, #256
	mov	r1, r3
	mov	r0, #0
	bl	safe_read
	mov	r3, r0
	str	r3, [fp, #-268]
	ldr	r2, [fp, #-268]
	sub	r3, fp, #264
	mov	r1, r3
	mov	r0, #1
	bl	safe_terminal_write
	ldr	r3, .L161+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L158
	sub	r2, fp, #268
	sub	r3, fp, #264
	mov	r1, r2
	mov	r0, r3
	bl	simple_deflate
.L158:
	ldr	r3, .L161+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L159
	ldr	r2, [fp, #-268]
	sub	r3, fp, #264
	mov	r1, r2
	mov	r0, r3
	bl	log_bytes_sent
.L159:
	ldr	r2, [fp, #-268]
	sub	r3, fp, #264
	mov	r1, r3
	ldr	r0, [fp, #-272]
	bl	safe_write
	nop
	ldr	r3, .L161
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L160
	bl	__stack_chk_fail
.L160:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L162:
	.align	2
.L161:
	.word	.LC34
	.word	compress_flag
	.word	log_flag
	.size	handle_read_from_keyboard, .-handle_read_from_keyboard
	.section	.rodata
	.align	2
.LC35:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	handle_read_from_socket
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_read_from_socket, %function
handle_read_from_socket:
	@ args = 0, pretend = 0, frame = 2064
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2064
	str	r0, [fp, #-2064]
	ldr	r3, .L170
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #256
	mov	r1, r3
	ldr	r0, [fp, #-2064]
	bl	safe_read
	mov	r3, r0
	str	r3, [fp, #-2060]
	ldr	r3, [fp, #-2060]
	cmp	r3, #0
	bne	.L164
	ldr	r3, [fp, #-2060]
	b	.L168
.L164:
	ldr	r3, .L170+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L166
	ldr	r2, [fp, #-2060]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	log_bytes_received
.L166:
	ldr	r3, .L170+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L167
	sub	r2, fp, #2048
	sub	r2, r2, #4
	sub	r2, r2, #8
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	simple_inflate
.L167:
	ldr	r2, [fp, #-2060]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	mov	r0, #1
	bl	safe_terminal_write
	ldr	r3, [fp, #-2060]
.L168:
	ldr	r2, .L170
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L169
	bl	__stack_chk_fail
.L169:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L171:
	.align	2
.L170:
	.word	.LC35
	.word	log_flag
	.word	compress_flag
	.size	handle_read_from_socket, .-handle_read_from_socket
	.section	.rodata
	.align	2
.LC36:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	read_leftover
	.syntax unified
	.arm
	.fpu softvfp
	.type	read_leftover, %function
read_leftover:
	@ args = 0, pretend = 0, frame = 2064
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2064
	str	r0, [fp, #-2064]
	ldr	r3, .L178
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	b	.L173
.L176:
	ldr	r3, .L178+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L174
	ldr	r2, [fp, #-2060]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	log_bytes_received
.L174:
	ldr	r3, .L178+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L175
	sub	r2, fp, #2048
	sub	r2, r2, #4
	sub	r2, r2, #8
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	simple_inflate
.L175:
	ldr	r2, [fp, #-2060]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	mov	r0, #1
	bl	safe_terminal_write
.L173:
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #256
	mov	r1, r3
	ldr	r0, [fp, #-2064]
	bl	safe_read
	mov	r3, r0
	str	r3, [fp, #-2060]
	ldr	r3, [fp, #-2060]
	cmp	r3, #0
	bne	.L176
	nop
	ldr	r3, .L178
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L177
	bl	__stack_chk_fail
.L177:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L179:
	.align	2
.L178:
	.word	.LC36
	.word	log_flag
	.word	compress_flag
	.size	read_leftover, .-read_leftover
	.section	.rodata
	.align	2
.LC37:
	.ascii	"stdin POLLERR detected: %s\012\000"
	.align	2
.LC38:
	.ascii	"socket POLLERR detected: %s\012\000"
	.align	2
.LC39:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	handle_port_option
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_port_option, %function
handle_port_option:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #36
	ldr	r3, .L192
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	bl	handle_socket
	str	r0, [fp, #-40]
	sub	r3, fp, #32
	mov	r2, #25
	mov	r1, #0
	mov	r0, r3
	bl	add_observer
	sub	r3, fp, #32
	add	r3, r3, #8
	mov	r2, #25
	ldr	r1, [fp, #-40]
	mov	r0, r3
	bl	add_observer
.L188:
	sub	r3, fp, #32
	mvn	r2, #0
	mov	r1, #2
	mov	r0, r3
	bl	safe_poll
	ldrsh	r3, [fp, #-26]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L181
	ldr	r0, [fp, #-40]
	bl	handle_read_from_keyboard
.L181:
	ldrsh	r3, [fp, #-18]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L182
	ldr	r0, [fp, #-40]
	bl	handle_read_from_socket
	str	r0, [fp, #-36]
	ldr	r3, [fp, #-36]
	cmp	r3, #0
	beq	.L191
.L182:
	ldrsh	r3, [fp, #-26]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	and	r3, r3, #16
	cmp	r3, #0
	bne	.L184
	ldrsh	r3, [fp, #-18]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	and	r3, r3, #16
	cmp	r3, #0
	beq	.L185
.L184:
	ldr	r0, [fp, #-40]
	bl	read_leftover
	b	.L180
.L185:
	ldrsh	r3, [fp, #-26]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	and	r3, r3, #8
	cmp	r3, #0
	beq	.L186
	ldr	r3, .L192+4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L192+8
	mov	r0, r4
	bl	fprintf
	b	.L180
.L186:
	ldrsh	r3, [fp, #-18]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	and	r3, r3, #8
	cmp	r3, #0
	beq	.L188
	ldr	r3, .L192+4
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L192+12
	mov	r0, r4
	bl	fprintf
	b	.L180
.L191:
	nop
.L180:
	ldr	r3, .L192
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L190
	bl	__stack_chk_fail
.L190:
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L193:
	.align	2
.L192:
	.word	.LC39
	.word	stderr
	.word	.LC37
	.word	.LC38
	.size	handle_port_option, .-handle_port_option
	.section	.rodata
	.align	2
.LC40:
	.ascii	"Error creating a file: %s\012\000"
	.text
	.align	2
	.global	safe_creat
	.syntax unified
	.arm
	.fpu softvfp
	.type	safe_creat, %function
safe_creat:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	ldr	r3, [fp, #-28]
	mov	r1, r3
	ldr	r0, [fp, #-24]
	bl	creat
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L195
	ldr	r3, .L197
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L197+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L195:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L198:
	.align	2
.L197:
	.word	stderr
	.word	.LC40
	.size	safe_creat, .-safe_creat
	.section	.rodata
	.align	2
.LC42:
	.ascii	"\000"
	.align	2
.LC43:
	.ascii	"Unrecognized argument detected\012%s\012\000"
	.align	2
.LC44:
	.ascii	"--port option is mandatory\012\000"
	.align	2
.LC41:
	.word	.LC0
	.word	1
	.word	0
	.word	112
	.word	.LC1
	.word	1
	.word	0
	.word	108
	.word	.LC2
	.word	0
	.word	0
	.word	99
	.word	0
	.word	0
	.word	0
	.word	0
	.align	2
.LC45:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	support_options
	.syntax unified
	.arm
	.fpu softvfp
	.type	support_options, %function
support_options:
	@ args = 0, pretend = 0, frame = 80
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #92
	str	r0, [fp, #-88]
	str	r1, [fp, #-92]
	ldr	r3, .L213
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	ldr	r3, .L213+4
	sub	ip, fp, #80
	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}
	ldmia	lr!, {r0, r1, r2, r3}
	stmia	ip!, {r0, r1, r2, r3}
	ldm	lr, {r0, r1, r2, r3}
	stm	ip, {r0, r1, r2, r3}
.L207:
	sub	r3, fp, #80
	mov	r2, #0
	str	r2, [sp]
	ldr	r2, .L213+8
	ldr	r1, [fp, #-92]
	ldr	r0, [fp, #-88]
	bl	getopt_long
	str	r0, [fp, #-84]
	ldr	r3, [fp, #-84]
	cmn	r3, #1
	beq	.L211
	ldr	r3, [fp, #-84]
	cmp	r3, #112
	beq	.L202
	ldr	r3, [fp, #-84]
	cmp	r3, #112
	bgt	.L203
	ldr	r3, [fp, #-84]
	cmp	r3, #99
	beq	.L204
	ldr	r3, [fp, #-84]
	cmp	r3, #108
	beq	.L205
	b	.L203
.L202:
	ldr	r3, .L213+12
	mov	r2, #1
	str	r2, [r3]
	ldr	r3, .L213+16
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r3, r0
	ldr	r2, .L213+20
	str	r3, [r2]
	b	.L206
.L205:
	ldr	r3, .L213+24
	mov	r2, #1
	str	r2, [r3]
	ldr	r3, .L213+16
	ldr	r3, [r3]
	mov	r1, #420
	mov	r0, r3
	bl	safe_creat
	mov	r3, r0
	ldr	r2, .L213+28
	str	r3, [r2]
	b	.L206
.L204:
	ldr	r3, .L213+32
	mov	r2, #1
	str	r2, [r3]
	bl	init_compression_streams
	b	.L206
.L203:
	ldr	r3, .L213+36
	ldr	r4, [r3]
	bl	getUsage
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L213+40
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L206:
	b	.L207
.L211:
	nop
	ldr	r3, .L213+12
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L212
	ldr	r3, .L213+36
	ldr	r3, [r3]
	mov	r2, #27
	mov	r1, #1
	ldr	r0, .L213+44
	bl	fwrite
	mov	r0, #1
	bl	exit
.L212:
	nop
	ldr	r3, .L213
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L209
	bl	__stack_chk_fail
.L209:
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L214:
	.align	2
.L213:
	.word	.LC45
	.word	.LC41
	.word	.LC42
	.word	port_flag
	.word	optarg
	.word	port
	.word	log_flag
	.word	log_fd
	.word	compress_flag
	.word	stderr
	.word	.LC43
	.word	.LC44
	.size	support_options, .-support_options
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-8]
	bl	support_options
	bl	save_terminal_params
	ldr	r0, .L216
	bl	atexit
	bl	verify_stdin_is_terminal
	bl	switch_to_noncanonical_mode
	bl	handle_port_option
	mov	r0, #0
	bl	exit
.L217:
	.align	2
.L216:
	.word	restore_terminal_params
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
