	.file	"123466.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"erro ao receber mensagem!"
.LC1:
	.string	"servidor: "
	.text
	.globl	receberMensagem
	.type	receberMensagem, @function
receberMensagem:
.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, 2048
	mov	QWORD PTR -2040[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -2040[rbp]
	mov	DWORD PTR -2024[rbp], eax
	lea	rax, -2016[rbp]
	mov	edx, 2000
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
.L4:
	lea	rsi, -2016[rbp]
	mov	eax, DWORD PTR -2024[rbp]
	mov	r9d, 0
	mov	r8d, 0
	mov	ecx, 0
	mov	edx, 2000
	mov	edi, eax
	call	recvfrom@PLT
	mov	DWORD PTR -2020[rbp], eax
	cmp	DWORD PTR -2020[rbp], 0
	jns	.L2
	lea	rdi, .LC0[rip]
	call	puts@PLT
	jmp	.L4
.L2:
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rdx, QWORD PTR stdout[rip]
	lea	rax, -2016[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	jmp	.L4
	.cfi_endproc
.LFE6:
	.size	receberMensagem, .-receberMensagem
	.section	.rodata
	.align 8
.LC2:
	.string	"para executar o cliente, digite: ./cliente <endereco ip do servidor>"
.LC3:
	.string	"erro ao criar socket!"
.LC4:
	.string	"Socket criado..."
	.align 8
.LC5:
	.string	"erro ao conectar com o servidor!"
.LC6:
	.string	"Conectado ao servidor..."
	.align 8
.LC7:
	.string	"Insira sua mensagem e tecle enter para enviar!"
	.align 8
.LC8:
	.string	"erro ao criar a thread que recebe do Servidor"
.LC9:
	.string	"erro ao enviar mensagem!\n\t-%s"
	.text
	.globl	main
	.type	main, @function
main:
.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, 2080
	mov	DWORD PTR -2068[rbp], edi
	mov	QWORD PTR -2080[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -2068[rbp], 1
	jg	.L7
	lea	rdi, .LC2[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
.L7:
	mov	rax, QWORD PTR -2080[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -2040[rbp], rax
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -2056[rbp], eax
	cmp	DWORD PTR -2056[rbp], 0
	jns	.L8
	lea	rdi, .LC3[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
.L8:
	lea	rdi, .LC4[rip]
	call	puts@PLT
	lea	rax, -2032[rbp]
	mov	edx, 16
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	WORD PTR -2032[rbp], 2
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	inet_addr@PLT
	mov	DWORD PTR -2028[rbp], eax
	mov	WORD PTR -2030[rbp], 4444
	lea	rcx, -2032[rbp]
	mov	eax, DWORD PTR -2056[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	mov	DWORD PTR -2052[rbp], eax
	cmp	DWORD PTR -2052[rbp], 0
	jns	.L9
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
.L9:
	lea	rdi, .LC6[rip]
	call	puts@PLT
	lea	rax, -2016[rbp]
	mov	edx, 2000
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	lea	rdi, .LC7[rip]
	call	puts@PLT
	mov	eax, DWORD PTR -2056[rbp]
	cdqe
	mov	rdx, rax
	lea	rax, -2048[rbp]
	mov	rcx, rdx
	lea	rdx, receberMensagem[rip]
	mov	esi, 0
	mov	rdi, rax
	call	pthread_create@PLT
	mov	DWORD PTR -2052[rbp], eax
	cmp	DWORD PTR -2052[rbp], 0
	je	.L11
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L12:
	lea	rdx, -2032[rbp]
	lea	rsi, -2016[rbp]
	mov	eax, DWORD PTR -2056[rbp]
	mov	r9d, 16
	mov	r8, rdx
	mov	ecx, 0
	mov	edx, 2000
	mov	edi, eax
	call	sendto@PLT
	mov	DWORD PTR -2052[rbp], eax
	cmp	DWORD PTR -2052[rbp], 0
	jns	.L11
	lea	rax, -2016[rbp]
	mov	rsi, rax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
.L11:
	mov	rdx, QWORD PTR stdin[rip]
	lea	rax, -2016[rbp]
	mov	esi, 2000
	mov	rdi, rax
	call	fgets@PLT
	test	rax, rax
	jne	.L12
	mov	eax, DWORD PTR -2056[rbp]
	mov	edi, eax
	mov	eax, 0
	call	close@PLT
	mov	edi, 0
	call	pthread_exit@PLT
	.cfi_endproc
.LFE7:
	.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	"123466.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"erro ao receber mensagem!\000"
	.align	2
.LC1:
	.ascii	"servidor: \000"
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	receberMensagem
	.syntax unified
	.arm
	.fpu softvfp
	.type	receberMensagem, %function
receberMensagem:
	@ args = 0, pretend = 0, frame = 2024
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2032
	str	r0, [fp, #-2024]
	ldr	r3, .L6
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-2024]
	str	r3, [fp, #-2016]
	sub	r3, fp, #2000
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #2000
	mov	r1, #0
	mov	r0, r3
	bl	memset
.L4:
	sub	r1, fp, #2000
	sub	r1, r1, #4
	sub	r1, r1, #4
	mov	r3, #0
	str	r3, [sp, #4]
	mov	r3, #0
	str	r3, [sp]
	mov	r3, #0
	mov	r2, #2000
	ldr	r0, [fp, #-2016]
	bl	recvfrom
	str	r0, [fp, #-2012]
	ldr	r3, [fp, #-2012]
	cmp	r3, #0
	bge	.L2
	ldr	r0, .L6+4
	bl	puts
	b	.L4
.L2:
	ldr	r0, .L6+8
	bl	printf
	ldr	r3, .L6+12
	ldr	r2, [r3]
	sub	r3, fp, #2000
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	fputs
	b	.L4
.L7:
	.align	2
.L6:
	.word	.LC2
	.word	.LC0
	.word	.LC1
	.word	stdout
	.size	receberMensagem, .-receberMensagem
	.section	.rodata
	.align	2
.LC3:
	.ascii	"para executar o cliente, digite: ./cliente <enderec"
	.ascii	"o ip do servidor>\000"
	.align	2
.LC4:
	.ascii	"erro ao criar socket!\000"
	.align	2
.LC5:
	.ascii	"Socket criado...\000"
	.align	2
.LC6:
	.ascii	"erro ao conectar com o servidor!\000"
	.align	2
.LC7:
	.ascii	"Conectado ao servidor...\000"
	.align	2
.LC8:
	.ascii	"Insira sua mensagem e tecle enter para enviar!\000"
	.align	2
.LC9:
	.ascii	"erro ao criar a thread que recebe do Servidor\000"
	.align	2
.LC10:
	.ascii	"erro ao enviar mensagem!\012\011-%s\000"
	.align	2
.LC11:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 2048
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2048
	sub	sp, sp, #8
	str	r0, [fp, #-2048]
	str	r1, [fp, #-2052]
	ldr	r3, .L16
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-2048]
	cmp	r3, #1
	bgt	.L9
	ldr	r0, .L16+4
	bl	puts
	mov	r0, #1
	bl	exit
.L9:
	ldr	r3, [fp, #-2052]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-2036]
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-2032]
	ldr	r3, [fp, #-2032]
	cmp	r3, #0
	bge	.L10
	ldr	r0, .L16+8
	bl	puts
	mov	r0, #1
	bl	exit
.L10:
	ldr	r0, .L16+12
	bl	puts
	sub	r3, fp, #2016
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #16
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #4
	sub	r3, r3, #2016
	sub	r3, r3, #4
	mov	r2, #2
	strh	r2, [r3]	@ movhi
	ldr	r0, [fp, #-2036]
	bl	inet_addr
	mov	r3, r0
	str	r3, [fp, #-2020]
	sub	r3, fp, #4
	sub	r3, r3, #2016
	sub	r3, r3, #4
	ldr	r2, .L16+16
	strh	r2, [r3, #2]	@ movhi
	sub	r3, fp, #2016
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #16
	mov	r1, r3
	ldr	r0, [fp, #-2032]
	bl	connect
	str	r0, [fp, #-2028]
	ldr	r3, [fp, #-2028]
	cmp	r3, #0
	bge	.L11
	ldr	r0, .L16+20
	bl	puts
	mov	r0, #1
	bl	exit
.L11:
	ldr	r0, .L16+24
	bl	puts
	sub	r3, fp, #2000
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #2000
	mov	r1, #0
	mov	r0, r3
	bl	memset
	ldr	r0, .L16+28
	bl	puts
	ldr	r3, [fp, #-2032]
	sub	r0, fp, #2032
	sub	r0, r0, #4
	sub	r0, r0, #4
	ldr	r2, .L16+32
	mov	r1, #0
	bl	pthread_create
	str	r0, [fp, #-2028]
	ldr	r3, [fp, #-2028]
	cmp	r3, #0
	beq	.L13
	ldr	r0, .L16+36
	bl	printf
	mov	r0, #1
	bl	exit
.L14:
	sub	r1, fp, #2000
	sub	r1, r1, #4
	sub	r1, r1, #4
	mov	r3, #16
	str	r3, [sp, #4]
	sub	r3, fp, #2016
	sub	r3, r3, #4
	sub	r3, r3, #4
	str	r3, [sp]
	mov	r3, #0
	mov	r2, #2000
	ldr	r0, [fp, #-2032]
	bl	sendto
	str	r0, [fp, #-2028]
	ldr	r3, [fp, #-2028]
	cmp	r3, #0
	bge	.L13
	sub	r3, fp, #2000
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L16+40
	bl	printf
.L13:
	ldr	r3, .L16+44
	ldr	r2, [r3]
	sub	r3, fp, #2000
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, #2000
	mov	r0, r3
	bl	fgets
	mov	r3, r0
	cmp	r3, #0
	bne	.L14
	ldr	r0, [fp, #-2032]
	bl	close
	mov	r0, #0
	bl	pthread_exit
.L17:
	.align	2
.L16:
	.word	.LC11
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	4444
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	receberMensagem
	.word	.LC9
	.word	.LC10
	.word	stdin
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
