	.file	"137170.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"127.0.0.1"
.LC1:
	.string	"pb bind : Serveur"
.LC2:
	.string	"Le serveur attend "
	.align 8
.LC3:
	.string	"et il est %02uh %02umin %02usec.\n"
.LC4:
	.string	"pb accept : Serveur"
.LC5:
	.string	"A enfin un client %d "
.LC6:
	.string	"la socket service vaut : %d \n"
	.align 8
.LC7:
	.string	"je suis un fils, mon pid est %d et celui de papa est : %d, ma SOCKET est %d \n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 104
	.cfi_offset 3, -24
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -96[rbp], 1
	mov	edi, 0
	call	time@PLT
	mov	QWORD PTR -80[rbp], rax
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	localtime@PLT
	mov	QWORD PTR -72[rbp], rax
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -92[rbp], eax
	mov	WORD PTR -64[rbp], 2
	lea	rdi, .LC0[rip]
	call	inet_addr@PLT
	mov	DWORD PTR -60[rbp], eax
	mov	edi, 50000
	call	htons@PLT
	mov	WORD PTR -62[rbp], ax
	mov	DWORD PTR -88[rbp], 16
	mov	edx, DWORD PTR -88[rbp]
	lea	rcx, -64[rbp]
	mov	eax, DWORD PTR -92[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	bind@PLT
	cmp	eax, -1
	jne	.L2
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	eax, DWORD PTR -92[rbp]
	mov	esi, 3
	mov	edi, eax
	call	listen@PLT
	mov	esi, 1
	mov	edi, 17
	call	signal@PLT
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 0
	call	time@PLT
	mov	QWORD PTR -80[rbp], rax
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	localtime@PLT
	mov	QWORD PTR -72[rbp], rax
	mov	rax, QWORD PTR -72[rbp]
	mov	ecx, DWORD PTR [rax]
	mov	rax, QWORD PTR -72[rbp]
	mov	edx, DWORD PTR 4[rax]
	mov	rax, QWORD PTR -72[rbp]
	mov	eax, DWORD PTR 8[rax]
	mov	esi, eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
.L5:
	mov	DWORD PTR -100[rbp], 16
	lea	rdx, -100[rbp]
	lea	rcx, -48[rbp]
	mov	eax, DWORD PTR -92[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	accept@PLT
	mov	DWORD PTR -84[rbp], eax
	cmp	DWORD PTR -84[rbp], -1
	jne	.L3
	lea	rdi, .LC4[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	mov	eax, DWORD PTR -96[rbp]
	mov	esi, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -96[rbp], 1
	mov	edi, 0
	call	time@PLT
	mov	QWORD PTR -80[rbp], rax
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	localtime@PLT
	mov	QWORD PTR -72[rbp], rax
	mov	rax, QWORD PTR -72[rbp]
	mov	ecx, DWORD PTR [rax]
	mov	rax, QWORD PTR -72[rbp]
	mov	edx, DWORD PTR 4[rax]
	mov	rax, QWORD PTR -72[rbp]
	mov	eax, DWORD PTR 8[rax]
	mov	esi, eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	call	fork@PLT
	test	eax, eax
	jne	.L4
	mov	eax, DWORD PTR -92[rbp]
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR -92[rbp]
	mov	edi, eax
	call	close@PLT
	lea	rcx, -101[rbp]
	mov	eax, DWORD PTR -84[rbp]
	mov	edx, 1
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	edi, 3
	call	sleep@PLT
	movzx	eax, BYTE PTR -101[rbp]
	add	eax, 1
	mov	BYTE PTR -101[rbp], al
	call	getppid@PLT
	mov	ebx, eax
	call	getpid@PLT
	mov	esi, eax
	mov	eax, DWORD PTR -84[rbp]
	mov	ecx, eax
	mov	edx, ebx
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rcx, -101[rbp]
	mov	eax, DWORD PTR -84[rbp]
	mov	edx, 1
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	edi, 0
	call	exit@PLT
.L4:
	mov	eax, DWORD PTR -84[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L5
	.cfi_endproc
.LFE6:
	.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	"137170.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"127.0.0.1\000"
	.align	2
.LC1:
	.ascii	"pb bind : Serveur\000"
	.align	2
.LC2:
	.ascii	"Le serveur attend \000"
	.align	2
.LC3:
	.ascii	"et il est %02uh %02umin %02usec.\012\000"
	.align	2
.LC4:
	.ascii	"pb accept : Serveur\000"
	.align	2
.LC5:
	.ascii	"A enfin un client %d \000"
	.align	2
.LC6:
	.ascii	"la socket service vaut : %d \012\000"
	.align	2
.LC7:
	.ascii	"je suis un fils, mon pid est %d et celui de papa es"
	.ascii	"t : %d, ma SOCKET est %d \012\000"
	.align	2
.LC8:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 72
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #76
	ldr	r3, .L7
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #1
	str	r3, [fp, #-68]
	mov	r0, #0
	bl	time
	mov	r3, r0
	str	r3, [fp, #-76]
	sub	r3, fp, #76
	mov	r0, r3
	bl	localtime
	str	r0, [fp, #-64]
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-60]
	mov	r3, #2
	strh	r3, [fp, #-48]	@ movhi
	ldr	r0, .L7+4
	bl	inet_addr
	mov	r3, r0
	str	r3, [fp, #-44]
	ldr	r0, .L7+8
	bl	htons
	mov	r3, r0
	strh	r3, [fp, #-46]	@ movhi
	mov	r3, #16
	str	r3, [fp, #-56]
	ldr	r2, [fp, #-56]
	sub	r3, fp, #48
	mov	r1, r3
	ldr	r0, [fp, #-60]
	bl	bind
	mov	r3, r0
	cmn	r3, #1
	bne	.L2
	ldr	r0, .L7+12
	bl	perror
	mov	r0, #1
	bl	exit
.L2:
	mov	r1, #3
	ldr	r0, [fp, #-60]
	bl	listen
	mov	r1, #1
	mov	r0, #17
	bl	signal
	ldr	r0, .L7+16
	bl	printf
	mov	r0, #0
	bl	time
	mov	r3, r0
	str	r3, [fp, #-76]
	sub	r3, fp, #76
	mov	r0, r3
	bl	localtime
	str	r0, [fp, #-64]
	ldr	r3, [fp, #-64]
	ldr	r1, [r3, #8]
	ldr	r3, [fp, #-64]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-64]
	ldr	r3, [r3]
	ldr	r0, .L7+20
	bl	printf
.L5:
	mov	r3, #16
	str	r3, [fp, #-72]
	sub	r2, fp, #72
	sub	r3, fp, #32
	mov	r1, r3
	ldr	r0, [fp, #-60]
	bl	accept
	str	r0, [fp, #-52]
	ldr	r3, [fp, #-52]
	cmn	r3, #1
	bne	.L3
	ldr	r0, .L7+24
	bl	perror
	mov	r0, #1
	bl	exit
.L3:
	ldr	r1, [fp, #-68]
	ldr	r0, .L7+28
	bl	printf
	ldr	r3, [fp, #-68]
	add	r3, r3, #1
	str	r3, [fp, #-68]
	mov	r0, #0
	bl	time
	mov	r3, r0
	str	r3, [fp, #-76]
	sub	r3, fp, #76
	mov	r0, r3
	bl	localtime
	str	r0, [fp, #-64]
	ldr	r3, [fp, #-64]
	ldr	r1, [r3, #8]
	ldr	r3, [fp, #-64]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-64]
	ldr	r3, [r3]
	ldr	r0, .L7+20
	bl	printf
	bl	fork
	mov	r3, r0
	cmp	r3, #0
	bne	.L4
	ldr	r1, [fp, #-60]
	ldr	r0, .L7+32
	bl	printf
	ldr	r0, [fp, #-60]
	bl	close
	sub	r3, fp, #77
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-52]
	bl	read
	mov	r0, #3
	bl	sleep
	ldrb	r3, [fp, #-77]	@ zero_extendqisi2
	add	r3, r3, #1
	and	r3, r3, #255
	strb	r3, [fp, #-77]
	bl	getpid
	mov	r4, r0
	bl	getppid
	mov	r2, r0
	ldr	r3, [fp, #-52]
	mov	r1, r4
	ldr	r0, .L7+36
	bl	printf
	sub	r3, fp, #77
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-52]
	bl	write
	mov	r0, #0
	bl	exit
.L4:
	ldr	r0, [fp, #-52]
	bl	close
	b	.L5
.L8:
	.align	2
.L7:
	.word	.LC8
	.word	.LC0
	.word	50000
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
