	.file	"25235.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"socket"
.LC1:
	.string	"connect"
.LC2:
	.string	"reading stream message"
.LC3:
	.string	"MSG: %s\n"
	.text
	.type	handle_socket, @function
handle_socket:
.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, 288
	mov	QWORD PTR -280[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	edx, 0
	mov	esi, 1
	mov	edi, 1
	call	socket@PLT
	mov	DWORD PTR -264[rbp], eax
	cmp	DWORD PTR -264[rbp], 0
	jns	.L2
	lea	rdi, .LC0[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	WORD PTR -256[rbp], 1
	mov	rax, QWORD PTR -280[rbp]
	lea	rdx, -256[rbp]
	add	rdx, 2
	mov	rsi, rax
	mov	rdi, rdx
	call	strcpy@PLT
	lea	rcx, -256[rbp]
	mov	eax, DWORD PTR -264[rbp]
	mov	edx, 110
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	test	eax, eax
	jns	.L3
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	eax, DWORD PTR -264[rbp]
	mov	edi, eax
	call	close@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	lea	rax, -144[rbp]
	mov	edx, 128
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	lea	rcx, -144[rbp]
	mov	eax, DWORD PTR -264[rbp]
	mov	edx, 128
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -260[rbp], eax
	cmp	DWORD PTR -260[rbp], 0
	jns	.L4
	lea	rdi, .LC2[rip]
	call	perror@PLT
	jmp	.L3
.L4:
	cmp	DWORD PTR -260[rbp], 0
	jle	.L3
	lea	rax, -144[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L3
	.cfi_endproc
.LFE6:
	.size	handle_socket, .-handle_socket
	.section	.rodata
.LC4:
	.string	"sockstub <socket-name>"
.LC5:
	.string	"%s\n"
	.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	QWORD PTR -16[rbp], rsi
	cmp	DWORD PTR -4[rbp], 2
	je	.L8
	mov	rax, QWORD PTR stderr[rip]
	lea	rdx, .LC4[rip]
	lea	rsi, .LC5[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, -1
	jmp	.L10
.L8:
	mov	rax, QWORD PTR -16[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	handle_socket
	mov	edi, 0
	call	exit@PLT
.L10:
	leave
	.cfi_def_cfa 7, 8
	ret
	.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	"25235.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"socket\000"
	.align	2
.LC1:
	.ascii	"connect\000"
	.align	2
.LC2:
	.ascii	"reading stream message\000"
	.align	2
.LC3:
	.ascii	"MSG: %s\012\000"
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	handle_socket, %function
handle_socket:
	@ args = 0, pretend = 0, frame = 264
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #264
	str	r0, [fp, #-264]
	ldr	r3, .L7
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r2, #0
	mov	r1, #1
	mov	r0, #1
	bl	socket
	str	r0, [fp, #-256]
	ldr	r3, [fp, #-256]
	cmp	r3, #0
	bge	.L2
	ldr	r0, .L7+4
	bl	perror
	mov	r0, #1
	bl	exit
.L2:
	mov	r3, #1
	strh	r3, [fp, #-248]	@ movhi
	sub	r3, fp, #248
	add	r3, r3, #2
	ldr	r1, [fp, #-264]
	mov	r0, r3
	bl	strcpy
	sub	r3, fp, #248
	mov	r2, #110
	mov	r1, r3
	ldr	r0, [fp, #-256]
	bl	connect
	mov	r3, r0
	cmp	r3, #0
	bge	.L3
	ldr	r0, .L7+8
	bl	perror
	ldr	r0, [fp, #-256]
	bl	close
	mov	r0, #1
	bl	exit
.L3:
	sub	r3, fp, #136
	mov	r2, #128
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #136
	mov	r2, #128
	mov	r1, r3
	ldr	r0, [fp, #-256]
	bl	read
	str	r0, [fp, #-252]
	ldr	r3, [fp, #-252]
	cmp	r3, #0
	bge	.L4
	ldr	r0, .L7+12
	bl	perror
	b	.L3
.L4:
	ldr	r3, [fp, #-252]
	cmp	r3, #0
	ble	.L3
	sub	r3, fp, #136
	mov	r1, r3
	ldr	r0, .L7+16
	bl	printf
	b	.L3
.L8:
	.align	2
.L7:
	.word	.LC4
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.size	handle_socket, .-handle_socket
	.section	.rodata
	.align	2
.LC5:
	.ascii	"sockstub <socket-name>\000"
	.align	2
.LC6:
	.ascii	"%s\012\000"
	.text
	.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	r3, [fp, #-8]
	cmp	r3, #2
	beq	.L10
	ldr	r3, .L13
	ldr	r3, [r3]
	ldr	r2, .L13+4
	ldr	r1, .L13+8
	mov	r0, r3
	bl	fprintf
	mvn	r3, #0
	b	.L12
.L10:
	ldr	r3, [fp, #-12]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	handle_socket
	mov	r0, #0
	bl	exit
.L12:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	stderr
	.word	.LC5
	.word	.LC6
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
